Package com.ipc.oce

Examples of com.ipc.oce.PropertiesReader


*/
public class Sample1 {

  public static void main(String[] args) throws IOException, ConfigurationException {
    // step 1 load properties via configuration file
    PropertiesReader pr = new PropertiesReader(new File("C:\\Developer\\Projects\\hel_default\\OCExportWeb\\WebContent\\WEB-INF\\oce.properties"));
   
   
    Properties configuration = pr.getPropertiesForInstance("inst01");
   
    // [step 2] load application driver (or use you can use default)
    ApplicationDriver driver = ApplicationDriver
        .loadDriver((String) configuration
            .get(PropertiesReader.OCE_CFG_DRIVER));
View Full Code Here


  private Sample2() {
    super();
  }
 
  private static OCApp getConnection() throws JIException, IOException, ConfigurationException{
    PropertiesReader pr = new PropertiesReader(new File("C:\\Developer\\Projects\\hel_default\\OCExportWeb\\WebContent\\WEB-INF\\oce.properties"));
    Properties configuration = pr.getPropertiesForInstance("inst01");
    ApplicationDriver driver = ApplicationDriver
        .loadDriver((String) configuration
            .get(PropertiesReader.OCE_CFG_DRIVER));
    OCApp app = OCApp.getNewInstance();
    app.setApplicationDriver(driver);
View Full Code Here

  private Sample3() {
    super();
  }
 
  private static OCApp getConnection() throws JIException, IOException, ConfigurationException{
    PropertiesReader pr = new PropertiesReader(new File("C:\\Developer\\Projects\\hel_default\\OCExportWeb\\WebContent\\WEB-INF\\oce.properties"));
    Properties configuration = pr.getPropertiesForInstance("buh");
    ApplicationDriver driver = ApplicationDriver
        .loadDriver((String) configuration
            .get(PropertiesReader.OCE_CFG_DRIVER));
    OCApp app = OCApp.getNewInstance();
    app.setApplicationDriver(driver);
View Full Code Here

  private static OCApp app = null;
  private int sessionNum = -1;
 
  @BeforeClass
  public static void setUpBeforeClass() throws Exception {
    PropertiesReader pr = new PropertiesReader(
        new File(
            "C:\\Developer\\Projects\\hel_default\\OCExportWeb\\WebContent\\WEB-INF\\oce.properties"));

    configuration = pr.getPropertiesForInstance("inst03");

    // [step 2] load application driver (or use you can use default)
    ApplicationDriver driver = ApplicationDriver
        .loadDriver((String) configuration
            .get(PropertiesReader.OCE_CFG_DRIVER));
View Full Code Here

  protected static OCApp app = null;
  protected int sessionNum = -1;
 
  @BeforeClass
  public static void setUpBeforeClass() throws Exception {
    PropertiesReader pr = new PropertiesReader(
        new File(
            "C:\\Developer\\Projects\\hel_default\\OCExportWeb\\WebContent\\WEB-INF\\oce.properties"));

    configuration = pr.getPropertiesForInstance("buh");

    // [step 2] load application driver (or use you can use default)
    ApplicationDriver driver = ApplicationDriver
        .loadDriver((String) configuration
            .get(PropertiesReader.OCE_CFG_DRIVER));
View Full Code Here

  private static Properties configuration = null;
  private static OCApp app = null;
 
  @BeforeClass
  public static void setUpBeforeClass() throws Exception {
    PropertiesReader pr = new PropertiesReader(
        new File("C:\\Developer\\Projects\\hel_default\\OCExportWeb\\WebContent\\WEB-INF\\oce.properties"));

    configuration = pr.getPropertiesForInstance("buh");

    // [step 2] load application driver (or use you can use default)
    ApplicationDriver driver = ApplicationDriver
        .loadDriver((String) configuration
            .get(PropertiesReader.OCE_CFG_DRIVER));
View Full Code Here

  /**
   * @throws java.lang.Exception
   */
  @BeforeClass
  public static void setUpBeforeClass() throws Exception {
    PropertiesReader pr = new PropertiesReader(
        new File(
            "C:\\Developer\\Projects\\hel_default\\OCExportWeb\\WebContent\\WEB-INF\\oce.properties"));

    configuration = pr.getPropertiesForInstance("buh");

    // [step 2] load application driver (or use you can use default)
    ApplicationDriver driver = ApplicationDriver
        .loadDriver((String) configuration
            .get(PropertiesReader.OCE_CFG_DRIVER));
View Full Code Here

    // check init parameters
    Properties configuration = null;
    String cfgPath = servletConfig.getInitParameter(CONFIG_FILE_PATH);
    String instanceName = servletConfig.getInitParameter(CONFIG_INST_NAME);
    if (cfgPath != null) {
      PropertiesReader pr = new PropertiesReader(new File(cfgPath));
      configuration = pr.getPropertiesForInstance(
          instanceName != null ? instanceName : PropertiesReader.OCE_DEFAULT_INSTANCE
          );
     
    } else {
      String driver = servletConfig.getInitParameter(PropertiesReader.OCE_CFG_DRIVER);
View Full Code Here

TOP

Related Classes of com.ipc.oce.PropertiesReader

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.