code: private IAtomContainerSet readAtomContainerSet(IAtomContainerSet som) {
          try {
              String line = input.readLine().trim();
              while (line != null) {
                  logger.debug("Line: ", line);
  
                  final String name = suffix(line);
  
                  try {
                      IAtomContainer molecule = sp.parseSmiles(line);
                      molecule.setProperty("SMIdbNAME", name);
                      som.addAtomContainer(molecule);
                  } catch (CDKException exception) {
                      logger.warn("This SMILES could not be parsed: ", line);
                      logger.warn("Because of: ", exception.getMessage());
                      logger.debug(exception);
                      IAtomContainer empty = som.getBuilder().newInstance(IAtomContainer.class, 0, 0, 0, 0);
                      empty.setProperty(IteratingSMILESReader.BAD_SMILES_INPUT, line);
                      som.addAtomContainer(empty);
                  }
                  if (input.ready()) {
                      line = input.readLine();
                  } else {
                      line = null;
                  }
              }
          } catch (Exception exception) {
              logger.error("Error while reading SMILES line: ", exception.getMessage());
              logger.debug(exception);
          }
          return som;
      }
docs: Private method that actually parses the input to read a ChemFile
  object.
  
  @param som The set of molecules that came from the file
  @return A ChemFile containing the data parsed from input.