Package org.apache.commons.collections

Examples of org.apache.commons.collections.ExtendedProperties


        {
            ToolboxConfiguration toolbox = new ToolboxConfiguration();
            toolbox.setScope(scope);
            addToolbox(toolbox);

            ExtendedProperties toolboxProps = factory.subset(scope);
            readTools(toolboxProps, toolbox);
            readProperties(toolboxProps, toolbox);
        }
    }
View Full Code Here


            tool.setClassname(classname);
            tool.setKey(key);
            toolbox.addTool(tool);

            // get tool properties prefixed by 'property'
            ExtendedProperties toolProps = tools.subset(key);
            readProperties(toolProps, tool);

            // ok, get tool properties that aren't prefixed by 'property'
            for (Iterator j = toolProps.getKeys(); j.hasNext(); )
            {
                String name = (String)j.next();
                if (!name.equals(tool.getKey()))
                {
                    tool.setProperty(name, toolProps.getString(name));
                }
            }

            // get special props explicitly
            String restrictTo = toolProps.getString("restrictTo");
            tool.setRestrictTo(restrictTo);
        }
    }
View Full Code Here

                Data data = new Data();
                data.setKey(key);
                data.setValue(dataset.getString(key));

                // get/set the type/converter properties
                ExtendedProperties props = dataset.subset(key);
                setProperties(props, data);

                addData(data);
            }
        }
View Full Code Here

        }

        // this will throw an exception if require is true and there
        // are no properties at the path.  if require is false, this
        // will return null when there's no properties at the path
        ExtendedProperties props = getProperties(path, require);
        if (props == null)
        {
            return false;
        }
View Full Code Here

        if (inputStream == null)
        {
            return null;
        }

        ExtendedProperties properties = new ExtendedProperties();
        try
        {
            properties.load(inputStream);
        }
        catch (IOException ioe)
        {
            String msg = "Failed to load properties at: "+path;
            getLog().error(msg, ioe);
View Full Code Here

     */
    public void setProperty(String key, Object value)
    {
        if (overridingProperties == null)
        {
            overridingProperties = new ExtendedProperties();
        }

        overridingProperties.setProperty(key, value);
    }
View Full Code Here

     */
    public void addProperty(String key, Object value)
    {
        if (overridingProperties == null)
        {
            overridingProperties = new ExtendedProperties();
        }

        overridingProperties.addProperty(key, value);
    }
View Full Code Here

     * @throws Exception When an error occurs during initialization.
     */
    public void init(String configurationFile)
        throws Exception
    {
        setProperties(new ExtendedProperties(configurationFile));
        init();
    }
View Full Code Here

     */
    public void setProperty(String key, Object value)
    {
        if (overridingProperties == null)
        {
            overridingProperties = new ExtendedProperties();
        }           
           
        overridingProperties.setProperty( key, value );
    }       
View Full Code Here

     */
    public void addProperty(String key, Object value)
    {
        if (overridingProperties == null)
        {
            overridingProperties = new ExtendedProperties();
        }           
           
        overridingProperties.addProperty( key, value );
    }
View Full Code Here

TOP

Related Classes of org.apache.commons.collections.ExtendedProperties

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.