Package java.util

Examples of java.util.Properties.propertyNames()


        }
        else if ( action.equals( "configuration" ) )
        {
            System.out.println( Main.getRes().getString( "Dump Wrapper Properties:" ) );
            Properties props = WrapperManager.getProperties();
            for ( Enumeration en = props.propertyNames(); en.hasMoreElements(); )
            {
                String name = (String)en.nextElement();
                System.out.println( "  " + name + "=" + props.getProperty( name ) );
            }
            System.out.println();
View Full Code Here


        settings.put(property.getKey(), propVal);
      }
    }
   
    Properties systemProps = System.getProperties();
    for (Enumeration it = systemProps.propertyNames(); it.hasMoreElements();)
    {
      String propName = (String) it.nextElement();
      if (propName.startsWith(JDT_PROPERTIES_PREFIX))
      {
        String propVal = systemProps.getProperty(propName);
View Full Code Here

     
      close = false;
      stream.close();
     
      JRPropertiesMap properties = new JRPropertiesMap();
      for (Enumeration names = props.propertyNames(); names.hasMoreElements(); )
      {
        String name = (String) names.nextElement();
        String value = props.getProperty(name);
        properties.setProperty(name, value);
      }
View Full Code Here

      finally
      {
         is.close();
      }

      for (Enumeration keys = props.propertyNames(); keys.hasMoreElements(); )
      {
         String key = (String) keys.nextElement();
         String value = props.getProperty(key);
         if (debug)
         {
View Full Code Here

      InputStream propertiesIs = null;
      try {
         propertiesIs = getClass().getClassLoader().getResourceAsStream("catalina.properties");
         Properties properties = new Properties();
         properties.load(propertiesIs);
         Enumeration enumeration = properties.propertyNames();
         while (enumeration.hasMoreElements()) {
             String name = (String) enumeration.nextElement();
             String value = properties.getProperty(name);
             if (value != null && (System.getProperty(name) == null)) {
                 System.setProperty(name, value);
View Full Code Here

        file = new File(fileName);
        if (file.exists()) {

          fin = new FileInputStream(file);
          props.load(fin);
          propNames = props.propertyNames();
          confs = new HashMap<String, String>(1);
          while (propNames.hasMoreElements()) {
            name = (String) propNames.nextElement();
            value = props.getProperty(name);
            confs.put(name, value);
View Full Code Here

             * Always cache using context class loader.
             */
            cacheFactory(contextClassLoader, factory);

            if( props!=null ) {
                Enumeration names = props.propertyNames();
                while (names.hasMoreElements()) {
                    String name = (String) names.nextElement();
                    String value = props.getProperty(name);
                    factory.setAttribute(name, value);
                }
View Full Code Here

    Properties properties = System.getProperties();
    Array list = new Array(properties.size());
    list.append("anvil.version", Any.create(anvil.Version.getVersion()));
    list.append("anvil.build", Any.create(anvil.Version.getBuild()));
    list.append("anvil.fullversion", Any.create(anvil.Version.getFullVersion()));
    Enumeration e = properties.propertyNames();
    while(e.hasMoreElements()) {
      String name = (String)e.nextElement();
      list.append(name, Any.create(properties.getProperty(name)));
    }
    return Any.create(list);
View Full Code Here

            }
            else {
                VariableManager varman = VariableManager.getInstance();
                Properties myProperties = new Properties();
                myProperties.load(inputStream);
                Enumeration propertyNames = myProperties.propertyNames();
                while (propertyNames.hasMoreElements()) {
                    String name = (String) propertyNames.nextElement();
                    String value = myProperties.getProperty(name);                   
                    varman.addIncludedVariable(name,value, configName);
                }
View Full Code Here

    public String[] getPropertyNames(String category) {
        if ( containsCategory(category) ) {
            // FIXME: include parent properties
            Properties properties = getProperties(category);           
            if (properties != null) {               
                Enumeration en = properties.propertyNames();
                Vector keys = new Vector();
                while ( en.hasMoreElements() ) {
                    String nm = (String)en.nextElement();                   
                    keys.add(nm);
                }
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.