Examples of ExtendedProperties


Examples of org.apache.commons.collections.ExtendedProperties

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

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

Examples of org.apache.commons.collections.ExtendedProperties

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

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

Examples of org.apache.commons.collections.ExtendedProperties

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

Examples of org.apache.commons.collections.ExtendedProperties

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

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

Examples of org.apache.commons.collections.ExtendedProperties

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

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

Examples of org.apache.commons.collections.ExtendedProperties

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

Examples of org.apache.commons.collections.ExtendedProperties

     *
     * @param input the InputStream to read from
     */
    public void read(InputStream input) throws IOException
    {
        ExtendedProperties props = new ExtendedProperties();
        props.load(input);

        // all factory settings should be prefixed with "tools"
        read(props.subset("tools"));
    }
View Full Code Here

Examples of org.apache.commons.collections.ExtendedProperties


    protected void readProperties(ExtendedProperties configProps,
                                  Configuration config)
    {
        ExtendedProperties properties = configProps.subset("property");
        for (Iterator i = properties.getKeys(); i.hasNext(); )
        {
            String name = (String)i.next();
            String value = properties.getString(name);

            ExtendedProperties propProps = properties.subset(name);
            if (propProps.isEmpty())
            {
                // then set this as a 'simple' property
                config.setProperty(name, value);
            }
            else
View Full Code Here

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

Examples of org.apache.commons.collections.ExtendedProperties

            tool.setKey(key);
            tool.setClassname(classname);
            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();
                tool.setProperty(name, toolProps.getString(name));
            }

            // get special props explicitly
            String restrictTo = toolProps.getString("restrictTo");
            tool.setRestrictTo(restrictTo);
        }
    }
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.