Examples of ConfigurationReader


Examples of com.blackbear.flatworm.ConfigurationReader

   
    /**
     * import a file.
     */
    private void importarArquivo() {
        final ConfigurationReader parser = new ConfigurationReader();
        try {
            final FileFormat fileFormat = parser.loadConfigurationFile( ARQUIVO_XML );
            final InputStream inputStream = new FileInputStream( ARQUIVO_TXT );
            final BufferedReader bufIn = new BufferedReader( new InputStreamReader( inputStream ) );
            MatchedRecord results;
            while ( ( results = fileFormat.getNextRecord( bufIn ) ) != null ) {
                if ( results.getRecordName().equals( "emprheader" ) ) {
View Full Code Here

Examples of com.common.platform.solr.client.config.ConfigurationReader

     * 注册所有资源入库对象<p>
     *
     * 初始化时,注册所有入库类型
     */
    private static void registerSolrClient(){
        ConfigurationReader reader = ConfigurationReader.getInstance();
        String solrUrl = reader.getString(ConfigurationKey.SOLR_BASE_URL);
       
        // 配置默认索引库客户端
        SolrClientHolder solrClientHolder = new SolrClientHolder(solrUrl);
        solrClientHolderCache.put(DEFAULT_STORE_NAME, solrClientHolder);
       
        // 配置其他索引库客户端
        String indexStore = reader.getString(ConfigurationKey.SOLR_OTHERS_INDEX_STORE_LIST);
        if(null != indexStore && !"".equals(indexStore)){
            String[] storeList = indexStore.split("\\,");
            for (String storeName : storeList) {
                SolrClientHolder otherSolrClientHolder = new SolrClientHolder(solrUrl + storeName);
                solrClientHolderCache.put(storeName, otherSolrClientHolder);
View Full Code Here

Examples of org.apache.airavata.credential.store.util.ConfigurationReader

        } catch (Exception e) {
            throw new ServletException("Error initializing database operations.", e);
        }

        try {
            configurationReader = new ConfigurationReader();
            super.init();
            certificateCredentialWriter = new CertificateCredentialWriter(dbUtil);
        } catch (Exception e) {
            throw new ServletException("Error initializing configuration reader.", e);
        }
View Full Code Here

Examples of org.apache.airavata.credential.store.util.ConfigurationReader

        super.init();

        try {
            if (configurationReader == null) {
                configurationReader = new ConfigurationReader();
            }
        } catch (CredentialStoreException e) {
            throw new ServletException(e);
        }
View Full Code Here

Examples of org.apache.airavata.credential.store.util.ConfigurationReader

        } catch (Exception e) {
            throw new ServletException("Error initializing database operations.", e);
        }

        try {
            configurationReader = new ConfigurationReader();
            super.init();
            certificateCredentialWriter = new CertificateCredentialWriter(dbUtil);
        } catch (Exception e) {
            throw new ServletException("Error initializing configuration reader.", e);
        }
View Full Code Here

Examples of org.apache.airavata.credential.store.util.ConfigurationReader

        } catch (Exception e) {
            throw new ServletException("Error initializing database operations.", e);
        }

        try {
            configurationReader = new ConfigurationReader();
        } catch (Exception e) {
            throw new ServletException("Error initializing configuration reader.", e);
        }

        super.init();
View Full Code Here

Examples of org.apache.fop.configuration.ConfigurationReader

            throw new FOPException("can't find default configuration file");
        }
        if (errorDump) {
            MessageHandler.logln("reading default configuration file");
        }
        ConfigurationReader reader =
            new ConfigurationReader(new InputSource(configfile));
        if (errorDump) {
            reader.setDumpError(true);
        }
        reader.start();

    }
View Full Code Here

Examples of org.apache.fop.configuration.ConfigurationReader

    public void loadUserconfiguration(File userConfigFile) {
        // read user configuration file
        if (userConfigFile != null) {
            MessageHandler.logln("reading user configuration file");
            ConfigurationReader reader =
                new ConfigurationReader(InputHandler.fileInputSource(userConfigFile));
            if (errorDump) {
                reader.setDumpError(true);
            }
            try {
                reader.start();
            } catch (org.apache.fop.apps.FOPException error) {
                MessageHandler.errorln("Could not load user configuration file "
                                       + userConfigFile + " - error: "
                                       + error.getMessage());
                MessageHandler.errorln("using default values");
                if (errorDump) {
                    reader.dumpError(error);
                }
            }
        }
    }
View Full Code Here

Examples of org.apache.fop.configuration.ConfigurationReader

            System.exit(1);
        }
        if (errorDump) {
            MessageHandler.logln("reading default configuration file");
        }
        ConfigurationReader reader =
          new ConfigurationReader (new InputSource(configfile));
        if (errorDump) {
            reader.setDumpError(true);
        }
        try {
            reader.start();
        } catch (org.apache.fop.apps.FOPException error) {
            MessageHandler.errorln("Fatal Error: Can't process default configuration file. \nProbably it is not well-formed.");
            if (errorDump) {
                reader.dumpError(error);
            }
            System.exit(1);
        }
    }
View Full Code Here

Examples of org.apache.fop.configuration.ConfigurationReader

    public void loadUserconfiguration(String userConfigFile) {
        //read user configuration file
        if (userConfigFile != null) {
            MessageHandler.logln("reading user configuration file");
            ConfigurationReader reader = new ConfigurationReader (
                                           CommandLine.fileInputSource(userConfigFile));
            if (errorDump) {
                reader.setDumpError(true);
            }
            try {
                reader.start();
            } catch (org.apache.fop.apps.FOPException error) {
                MessageHandler.errorln(
                  "Can't find user configuration file " +
                  userConfigFile);
                MessageHandler.errorln("using default values");
                if (errorDump) {
                    reader.dumpError(error);
                }
            }
        }
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.