Package org.codehaus.plexus.util.xml

Examples of org.codehaus.plexus.util.xml.Xpp3Dom.addChild()


        result.setValue(config.getValue(null));
        for (String name : config.getAttributeNames()) {
            result.setAttribute(name, config.getAttribute(name));
        }
        for (PlexusConfiguration child : config.getChildren()) {
            result.addChild(toXpp3Dom(child));
        }
        return result;
    }
}
View Full Code Here


     * @return The elements transformed into the Maven-native XML format
     */
    public static Xpp3Dom configuration(Element... elements) {
        Xpp3Dom dom = new Xpp3Dom("configuration");
        for (Element e : elements) {
            dom.addChild(e.toDom());
        }
        return dom;
    }

    /**
 
View Full Code Here

            Xpp3Dom dom = new Xpp3Dom(name);
            if (text != null) {
                dom.setValue(text);
            }
            for (Element e : children) {
                dom.addChild(e.toDom());
            }
            for(Attribute attribute : attributes.attributes) {
                dom.setAttribute(attribute.name, attribute.value);
            }
View Full Code Here

                            for ( int i = 0, size = mergedConfiguration.getChildren().length; i < size; i++ )
                            {
                                if ( mojoDescriptor.getParameterMap().containsKey(
                                                                                   mergedConfiguration.getChildren()[i].getName() ) )
                                {
                                    cleanedConfiguration.addChild( mergedConfiguration.getChildren()[i] );
                                }
                            }
                        }
                        if ( getLog().isDebugEnabled() )
                        {
View Full Code Here

        {
            locationAttribute = EclipseWtpApplicationXMLWriter.XMLNS_SCHEMA_LOCATION;
        }
        result.setAttribute( locationAttribute,
                             "http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/application_1_4.xsd" );
        result.addChild( new Xpp3Dom( EclipseWtpApplicationXMLWriter.APPLICATION_XML_DESCRIPTION ) );
        Xpp3Dom name = new Xpp3Dom( EclipseWtpApplicationXMLWriter.APPLICATION_XML_DISPLAY_NAME );
        name.setValue( this.config.getEclipseProjectName() );
        result.addChild( name );
        return result;
    }
View Full Code Here

            }
        } );
        Xpp3Dom resultClasspath = new Xpp3Dom( CLASSPATH );
        for ( int index = 0; index < children.length; index++ )
        {
            resultClasspath.addChild( children[index] );
        }
        return resultClasspath;
    }

    /**
 
View Full Code Here

        result.setAttribute( XMLNS, "http://java.sun.com/xml/ns/j2ee" );
        result.setAttribute( XMLNS_XSI, "http://www.w3.org/2001/XMLSchema-instance" );
        result.setAttribute( XMLNS_SCHEMA_LOCATION,
                             "http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/application_"
                                 + jeeVersion.charAt( 0 ) + "_" + jeeVersion.charAt( 2 ) + ".xsd" );
        result.addChild( new Xpp3Dom( APPLICATION_XML_DESCRIPTION ) );
        Xpp3Dom name = new Xpp3Dom( APPLICATION_XML_DISPLAY_NAME );
        name.setValue( config.getProject().getArtifactId() );
        result.addChild( name );
        return result;
    }
View Full Code Here

                {
                    for ( Xpp3Dom parameter : mergedConfiguration.getChildren() )
                    {
                        if ( mojoDescriptor.getParameterMap().containsKey( parameter.getName() ) )
                        {
                            cleanedConfiguration.addChild( parameter );
                        }
                    }
                }
                if ( getLog().isDebugEnabled() )
                {
View Full Code Here

            dom.setAttribute( attrib, config.getAttribute( attrib, null ) );
        }

        for ( int n = config.getChildCount(), i = 0; i < n; i++ )
        {
            dom.addChild( convert( config.getChild( i ) ) );
        }

        return dom;
    }
View Full Code Here

            }
        } );
        Xpp3Dom resultClasspath = new Xpp3Dom( CLASSPATH );
        for ( int index = 0; index < children.length; index++ )
        {
            resultClasspath.addChild( children[index] );
        }
        return resultClasspath;
    }

    /**
 
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.