Class ComponentsXmlResourceTransformer

  • All Implemented Interfaces:
    ResourceTransformer

    public class ComponentsXmlResourceTransformer
    extends java.lang.Object
    implements ResourceTransformer
    A resource processor that aggregates plexus components.xml files.
    • Field Detail

      • components

        private java.util.Map<java.lang.String,​org.codehaus.plexus.util.xml.Xpp3Dom> components
      • COMPONENTS_XML_PATH

        public static final java.lang.String COMPONENTS_XML_PATH
        See Also:
        Constant Field Values
    • Constructor Detail

      • ComponentsXmlResourceTransformer

        public ComponentsXmlResourceTransformer()
    • Method Detail

      • processResource

        public void processResource​(java.lang.String resource,
                                    java.io.InputStream is,
                                    java.util.List<Relocator> relocators)
                             throws java.io.IOException
        Description copied from interface: ResourceTransformer
        Transform an individual resource
        Specified by:
        processResource in interface ResourceTransformer
        Parameters:
        resource - The resoure name
        is - An input stream for the resource, the implementation should *not* close this stream
        relocators - A list of relocators
        Throws:
        java.io.IOException - When the IO blows up
      • modifyOutputStream

        public void modifyOutputStream​(java.util.jar.JarOutputStream jos)
                                throws java.io.IOException
        Specified by:
        modifyOutputStream in interface ResourceTransformer
        Throws:
        java.io.IOException
      • getTransformedResource

        byte[] getTransformedResource()
                               throws java.io.IOException
        Throws:
        java.io.IOException
      • getRelocatedClass

        private java.lang.String getRelocatedClass​(java.lang.String className,
                                                   java.util.List<Relocator> relocators)
      • getValue

        private static java.lang.String getValue​(org.codehaus.plexus.util.xml.Xpp3Dom dom,
                                                 java.lang.String element)
      • setValue

        private static void setValue​(org.codehaus.plexus.util.xml.Xpp3Dom dom,
                                     java.lang.String element,
                                     java.lang.String value)