Package ca.carleton.gcrc.utils

Examples of ca.carleton.gcrc.utils.PropertiesWriter


      File installPropFile = new File(configDir,"install.properties");
      FileOutputStream fos = null;
      try {
        fos = new FileOutputStream(installPropFile);
        OutputStreamWriter osw = new OutputStreamWriter(fos,"UTF-8");
        PropertiesWriter propWriter = new PropertiesWriter(osw);
        propWriter.write(publicProps);
       
        osw.flush();
       
      } catch(Exception e) {
        throw new Exception("Unable to write config properties to: "+installPropFile.getAbsolutePath(), e);
       
      } finally {
        if( null != fos ){
          try{
            fos.close();
          } catch(Exception e) {
            // Ignore
          }
        }
      }
    }
   
    // Write sensitive file
    {
      File sensitivePropFile = new File(configDir,"sensitive.properties");
      FileOutputStream fos = null;
      try {
        fos = new FileOutputStream(sensitivePropFile);
        OutputStreamWriter osw = new OutputStreamWriter(fos,"UTF-8");
        PropertiesWriter propWriter = new PropertiesWriter(osw);
        propWriter.write(sensitiveProps);
       
        osw.flush();
       
      } catch(Exception e) {
        throw new Exception("Unable to write config properties to: "+sensitivePropFile.getAbsolutePath(), e);
View Full Code Here


      File installPropFile = new File(configDir,"install.properties");
      FileOutputStream fos = null;
      try {
        fos = new FileOutputStream(installPropFile);
        OutputStreamWriter osw = new OutputStreamWriter(fos,"UTF-8");
        PropertiesWriter propWriter = new PropertiesWriter(osw);
        propWriter.write(publicProps);
       
        osw.flush();
       
      } catch(Exception e) {
        throw new Exception("Unable to write config properties to: "+installPropFile.getAbsolutePath(), e);
       
      } finally {
        if( null != fos ){
          try{
            fos.close();
          } catch(Exception e) {
            // Ignore
          }
        }
      }
    }
   
    // Write sensitive file
    {
      File sensitivePropFile = new File(configDir,"sensitive.properties");
      FileOutputStream fos = null;
      try {
        fos = new FileOutputStream(sensitivePropFile);
        OutputStreamWriter osw = new OutputStreamWriter(fos,"UTF-8");
        PropertiesWriter propWriter = new PropertiesWriter(osw);
        propWriter.write(sensitiveProps);
       
        osw.flush();
       
      } catch(Exception e) {
        throw new Exception("Unable to write config properties to: "+sensitivePropFile.getAbsolutePath(), e);
View Full Code Here

      File installPropFile = new File(configDir,"install.properties");
      FileOutputStream fos = null;
      try {
        fos = new FileOutputStream(installPropFile);
        OutputStreamWriter osw = new OutputStreamWriter(fos,"UTF-8");
        PropertiesWriter propWriter = new PropertiesWriter(osw);
        propWriter.write(publicProps);
       
        osw.flush();
       
      } catch(Exception e) {
        throw new Exception("Unable to write config properties to: "+installPropFile.getAbsolutePath(), e);
       
      } finally {
        if( null != fos ){
          try{
            fos.close();
          } catch(Exception e) {
            // Ignore
          }
        }
      }
    }
   
    // Write sensitive file
    {
      File sensitivePropFile = new File(configDir,"sensitive.properties");
      FileOutputStream fos = null;
      try {
        fos = new FileOutputStream(sensitivePropFile);
        OutputStreamWriter osw = new OutputStreamWriter(fos,"UTF-8");
        PropertiesWriter propWriter = new PropertiesWriter(osw);
        propWriter.write(sensitiveProps);
       
        osw.flush();
       
      } catch(Exception e) {
        throw new Exception("Unable to write config properties to: "+sensitivePropFile.getAbsolutePath(), e);
View Full Code Here

      File installPropFile = new File(configDir,"install.properties");
      FileOutputStream fos = null;
      try {
        fos = new FileOutputStream(installPropFile);
        OutputStreamWriter osw = new OutputStreamWriter(fos,"UTF-8");
        PropertiesWriter propWriter = new PropertiesWriter(osw);
        propWriter.write(publicProps);
       
        osw.flush();
       
      } catch(Exception e) {
        throw new Exception("Unable to write config properties to: "+installPropFile.getAbsolutePath(), e);
       
      } finally {
        if( null != fos ){
          try{
            fos.close();
          } catch(Exception e) {
            // Ignore
          }
        }
      }
    }
   
    // Write sensitive file
    {
      File sensitivePropFile = new File(configDir,"sensitive.properties");
      FileOutputStream fos = null;
      try {
        fos = new FileOutputStream(sensitivePropFile);
        OutputStreamWriter osw = new OutputStreamWriter(fos,"UTF-8");
        PropertiesWriter propWriter = new PropertiesWriter(osw);
        propWriter.write(sensitiveProps);
       
        osw.flush();
       
      } catch(Exception e) {
        throw new Exception("Unable to write config properties to: "+sensitivePropFile.getAbsolutePath(), e);
View Full Code Here

TOP

Related Classes of ca.carleton.gcrc.utils.PropertiesWriter

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.