Package org.jfree.xml.util

Examples of org.jfree.xml.util.AttributeDefinition


                attributes.setAttribute(mPlexAttribute, mPlexValue);
            }
            final AttributeDefinition[] attribDefs = this.factory.getAttributeDefinitions();
            final ArrayList properties = new ArrayList();
            for (int i = 0; i < attribDefs.length; i++) {
                final AttributeDefinition adef = attribDefs[i];
                final String pName = adef.getAttributeName();
                final Object propValue = this.factory.getProperty(adef.getPropertyName());
                if (propValue != null) {
                    Log.debug(
                        "Here: " + this.factory.getBaseClass() + " -> " + adef.getPropertyName()
                    );
                    final String value = adef.getHandler().toAttributeValue(propValue);
                    if (value != null) {
                        attributes.setAttribute(pName, value);
                    }
                }
                properties.add(adef.getPropertyName());
            }
            writer.writeTag(tagName, attributes, false);
            writer.startBlock();

            final PropertyDefinition[] propertyDefs = this.factory.getPropertyDefinitions();
View Full Code Here


    protected void startParsing(final Attributes attrs) throws SAXException {

        try {
            final AttributeDefinition[] attribs = this.objectFactory.getAttributeDefinitions();
            for (int i = 0; i < attribs.length; i++) {
                final AttributeDefinition attrDef = attribs[i];
                final String value = attrs.getValue(attrDef.getAttributeName());
                if (value == null) {
                    continue;
                }
                final Object o = attrDef.getHandler().toPropertyValue(value);
                this.objectFactory.setProperty(attrDef.getPropertyName(), o);
            }
        }
        catch (ObjectDescriptionException ode) {
            throw new SAXException(ode);
        }
View Full Code Here

    protected void startParsing(final Attributes attrs) throws SAXException {

        try {
            final AttributeDefinition[] attribs = this.objectFactory.getAttributeDefinitions();
            for (int i = 0; i < attribs.length; i++) {
                final AttributeDefinition attrDef = attribs[i];
                final String value = attrs.getValue(attrDef.getAttributeName());
                if (value == null) {
                    // System.out.println("No value for " + attrDef.getAttributeName());
                    continue;
                }
                final Object o = attrDef.getHandler().toPropertyValue(value);
                this.objectFactory.setProperty(attrDef.getPropertyName(), o);
            }
        }
        catch (ObjectDescriptionException ode) {
            throw new SAXException(ode);
        }
View Full Code Here

                attributes.setAttribute(mPlexAttribute, mPlexValue);
            }
            final AttributeDefinition[] attribDefs = this.factory.getAttributeDefinitions();
            final ArrayList properties = new ArrayList();
            for (int i = 0; i < attribDefs.length; i++) {
                final AttributeDefinition adef = attribDefs[i];
                final String pName = adef.getAttributeName();
                final Object propValue = this.factory.getProperty(adef.getPropertyName());
                if (propValue != null) {
                    Log.debug(
                        "Here: " + this.factory.getBaseClass() + " -> " + adef.getPropertyName()
                    );
                    final String value = adef.getHandler().toAttributeValue(propValue);
                    if (value != null) {
                        attributes.setAttribute(pName, value);
                    }
                }
                properties.add(adef.getPropertyName());
            }
            writer.writeTag(tagName, attributes, false);
            writer.startBlock();

            final PropertyDefinition[] propertyDefs = this.factory.getPropertyDefinitions();
View Full Code Here

TOP

Related Classes of org.jfree.xml.util.AttributeDefinition

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.