code: private ISimpleChemObjectReader getReader(IChemFormat format) {
  
          // create a new reader if not mapped
          if (!readerMap.containsKey(format)) {
  
              ISimpleChemObjectReader reader;
              if (format instanceof MDLV2000Format)
                  reader = new MDLV2000Reader();
              else if (format instanceof MDLV3000Format)
                  reader = new MDLV3000Reader();
              else if (format instanceof MDLFormat)
                  reader = new MDLReader();
              else
                  throw new IllegalArgumentException("Unexpected format: " + format);
              reader.setErrorHandler(this.errorHandler);
              reader.setReaderMode(this.mode);
              if (currentFormat instanceof MDLV2000Format) {
                  reader.addSettings(getSettings());
              }
  
              readerMap.put(format, reader);
  
          }
  
          return readerMap.get(format);
  
      }
docs: Method will return an appropriate reader for the provided format. Each reader is stored
  in a map, if no reader is available for the specified format a new reader is created. The
  {@see ISimpleChemObjectReadr#setErrorHandler(IChemObjectReaderErrorHandler)} and
  {@see ISimpleChemObjectReadr#setReaderMode(DefaultIteratingChemObjectReader)}
  methods are set.
  
  @param  format The format to obtain a reader for
  @return        instance of a reader appropriate for the provided format