code: public void addDynamicMacro(String name, Factory factory) {
  
          if (m_factories == null) {
              m_factories = new HashMap<String, Factory>();
          }
          m_factories.put(name, factory);
      }
docs: Adds a macro whose value will be dynamically generated at macro resolution time.<p>
  
  The value will be generated for each occurence of the macro in a string.<p>
  
  @param name the name of the macro
  @param factory the macro value generator