Package org.apache.uima.tools.cfe.config.util

Examples of org.apache.uima.tools.cfe.config.util.ConfigResourceFactoryImpl


    private static boolean m_init = false;
   
    private DocumentRoot load(String filename) throws IOException
    {
        if (!m_init) {
            Resource.Factory.Registry.INSTANCE.getExtensionToFactoryMap().put("xml", new ConfigResourceFactoryImpl());
            ConfigPackageImpl.init();
            ConfigFactoryImpl.init();
            m_init = true;
        }
     
      ConfigResourceImpl resource = (ConfigResourceImpl)(new ConfigResourceFactoryImpl()).createResource(URI.createURI("file://" + filename));
      resource.load(null);
      DocumentRoot documentRoot = (DocumentRoot)resource.getContents().get(0);
      return documentRoot;
    }
View Full Code Here

TOP

Related Classes of org.apache.uima.tools.cfe.config.util.ConfigResourceFactoryImpl

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.