code: public Mapping getInstance(String name) throws MappingNotFoundException {
          LOG.info("mappingFactory.getInstance: " + name);
  
          Mapping mapping = null;
          try {
              for (int i = 0; i < mappingList.size(); i++) {
                  MappingParameters mappingParameters = mappingList.get(i);
  
                  if (mappingParameters.getName().equals(name)) {
                      LOG.info(mappingParameters.getName() + " ("
                              + mappingParameters.getClassName()
                              + ") mapping found");
  
                      // instantiate the mapping
                      LOG.debug("instance the mapping");
                      mapping = (Mapping) (Class.forName(mappingParameters
                              .getClassName())).newInstance();
  
                      // set the default parameters
                      LOG.debug("set the default parameters");
                      mapping.setParameters(mappingParameters.getParameters());
                  }
              }
          } catch (ClassNotFoundException e) {
              throw new MappingNotFoundException(name + " Mapping not found.");
          } catch (Exception e) {
              LOG.error("woooops", e);
          }
  
          return mapping;
      }
docs: Returns the <i>id</i> of the specified Mapping and adds the Mapping to
  the lexicon if it is not present yet.
  <p>
  If the lexicon is read only, mappings not already present in the lexicon
  will not be added and a <code>null</code> <i>id</i> will be returned.
  
  @param name
  the string representation of the Mapping.
  @return the <i>id</i> of the specified Mapping.