Class TransformationSet


  • public class TransformationSet
    extends java.lang.Object
    An instance of this class is used to specify a set of files, which are transformed by a common XSLT stylesheet.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      NameValuePair[] getAttributes()
      Returns the attributes, which should be set on the transformer factory.
      java.io.File getDir()
      Returns a directory, which is scanned for files to transform.
      java.lang.String[] getExcludes()
      Returns patterns of files, which are being excluded from the transformation set.
      NameValuePair[] getFeatures()
      Returns the features, which should be set on the transformer factory.
      org.codehaus.plexus.components.io.filemappers.FileMapper[] getFileMappers()
      Returns a set of file mappers, which are being used to convert the generated files name.
      java.lang.String[] getIncludes()
      Returns patterns of files, which are being included into the transformation set.
      java.lang.String[] getOtherDepends()
      Returns patterns of additional files, which are being considered for the uptodate check.
      java.io.File getOutputDir()
      Returns the output directory, where the generated files are being placed.
      NameValuePair[] getOutputProperties()
      Returns the transformers output properties.
      NameValuePair[] getParameters()
      Returns the stylesheet parameters.
      java.lang.String getStylesheet()
      Returns the XSLT stylesheet, which is being used to control the transformation.
      boolean isAddedToClasspath()
      Returns, whether the output directory is added to the classpath.
      boolean isSkipDefaultExcludes()
      Returns, whether Maven's default excludes are being ignored.
      boolean isValidating()
      Returns, whether the transformer should create validating XML parsers for reading XML documents.
      boolean isXincludeAware()
      Returns, whether the transformer should create xinclude aware XML parsers for reading XML documents.
      void setAddedToClasspath​(boolean addedToClasspath)
      Sets, whether the output directory is added to the classpath.
      void setAttributes​(NameValuePair[] pAttributes)
      Sets the attributes, which should be set on the transformer factory.
      void setDir​(java.io.File pDir)
      Sets the name of a directory, which is scanned for files to transform.
      void setExcludes​(java.lang.String[] pExcludes)
      Sets patterns of files, which are being excluded from the transformation set.
      void setFeatures​(NameValuePair[] pFeatures)
      Sets the features, which should be set on the transformer factory.
      void setFileMappers​(org.codehaus.plexus.components.io.filemappers.FileMapper[] pFileMappers)
      Sets a set of file mappers, which are being used to convert the generated files name.
      void setIncludes​(java.lang.String[] pIncludes)
      Sets patterns of files, which are being included into the transformation set.
      void setOtherDepends​(java.lang.String[] pOtherDepends)
      Sets patterns of additional files, which are being considered for the uptodate check.
      void setOutputDir​(java.io.File pOutputDir)
      Sets the output directory, where the generated files are being placed.
      void setOutputProperties​(NameValuePair[] pOutputProperties)
      Sets the transformers output properties.
      void setParameters​(NameValuePair[] pParameters)
      Sets the stylesheet parameters.
      void setSkipDefaultExcludes​(boolean pSkipDefaultExcludes)
      Sets, whether Maven's default excludes are being ignored.
      void setStylesheet​(java.lang.String pStylesheet)
      Sets the XSLT stylesheet, which is being used to control the transformation.
      void setValidating​(boolean pValidating)
      Sets, whether the transformer should create validating XML parsers for reading XML documents.
      void setXincludeAware​(boolean pXIncludeAware)
      Sets, whether the transformer should create xinclude aware XML parsers for reading XML documents.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • stylesheet

        private java.lang.String stylesheet
      • dir

        private java.io.File dir
      • outputDir

        private java.io.File outputDir
      • addedToClasspath

        private boolean addedToClasspath
      • includes

        private java.lang.String[] includes
      • excludes

        private java.lang.String[] excludes
      • skipDefaultExcludes

        private boolean skipDefaultExcludes
      • otherDepends

        private java.lang.String[] otherDepends
      • fileMappers

        private org.codehaus.plexus.components.io.filemappers.FileMapper[] fileMappers
      • validating

        private boolean validating
      • xincludeAware

        private boolean xincludeAware
    • Constructor Detail

      • TransformationSet

        public TransformationSet()
    • Method Detail

      • setExcludes

        public void setExcludes​(java.lang.String[] pExcludes)
        Sets patterns of files, which are being excluded from the transformation set.
        Parameters:
        pExcludes - Patterns of files, which are being excluded.
      • setIncludes

        public void setIncludes​(java.lang.String[] pIncludes)
        Sets patterns of files, which are being included into the transformation set.
        Parameters:
        pIncludes - Patterns of files, which are being included.
      • setOtherDepends

        public void setOtherDepends​(java.lang.String[] pOtherDepends)
        Sets patterns of additional files, which are being considered for the uptodate check.
        Parameters:
        pOtherDepends - Patters of other files, which are being considered for the uptodate check.
      • setParameters

        public void setParameters​(NameValuePair[] pParameters)
        Sets the stylesheet parameters.
        Parameters:
        pParameters - Stylesheet parameters
      • getDir

        public java.io.File getDir()
        Returns a directory, which is scanned for files to transform.
        Returns:
        The base directory to scan for files to transform.
      • getExcludes

        public java.lang.String[] getExcludes()
        Returns patterns of files, which are being excluded from the transformation set.
        Returns:
        Patterns of files, which are being excluded.
        See Also:
        setExcludes(String[]), getIncludes()
      • getIncludes

        public java.lang.String[] getIncludes()
        Returns patterns of files, which are being included into the transformation set.
        Returns:
        Patterns of files, which are being included.
        See Also:
        setIncludes(String[]), getExcludes()
      • getOtherDepends

        public java.lang.String[] getOtherDepends()
        Returns patterns of additional files, which are being considered for the uptodate check.
        Returns:
        Patters of other files, which are being considered for the uptodate check.
      • getOutputDir

        public java.io.File getOutputDir()
        Returns the output directory, where the generated files are being placed. Defaults to {project.build.directory}/generated-resources/xml/xslt.
        Returns:
        Output directory for generated files.
      • getParameters

        public NameValuePair[] getParameters()
        Returns the stylesheet parameters.
        Returns:
        Stylesheet parameters
      • getStylesheet

        public java.lang.String getStylesheet()
        Returns the XSLT stylesheet, which is being used to control the transformation.
        Returns:
        The XSLT stylesheet to read.
      • isAddedToClasspath

        public boolean isAddedToClasspath()
        Returns, whether the output directory is added to the classpath. Defaults to false.
        Returns:
        True, if the getOutputDir() is being added to the classpath. Otherwise false.
      • isSkipDefaultExcludes

        public boolean isSkipDefaultExcludes()
        Returns, whether Maven's default excludes are being ignored. Defaults to false (Default excludes are being used).
        Returns:
        False, if default excludes are being applied. Otherwise true.
      • setAddedToClasspath

        public void setAddedToClasspath​(boolean addedToClasspath)
        Sets, whether the output directory is added to the classpath. Defaults to false.
        Parameters:
        addedToClasspath - True, if the getOutputDir() is being added to the classpath. Otherwise false.
      • setDir

        public void setDir​(java.io.File pDir)
        Sets the name of a directory, which is scanned for files to transform.
        Parameters:
        pDir - The base directory to scan for files to transform.
      • setOutputDir

        public void setOutputDir​(java.io.File pOutputDir)
        Sets the output directory, where the generated files are being placed. Defaults to {project.build.directory}/generated-resources/xml/xslt.
        Parameters:
        pOutputDir - Output directory for generated files.
      • setSkipDefaultExcludes

        public void setSkipDefaultExcludes​(boolean pSkipDefaultExcludes)
        Sets, whether Maven's default excludes are being ignored. Defaults to false (Default excludes are being used).
        Parameters:
        pSkipDefaultExcludes - False, if default excludes are being applied. Otherwise true.
      • setStylesheet

        public void setStylesheet​(java.lang.String pStylesheet)
        Sets the XSLT stylesheet, which is being used to control the transformation.
        Parameters:
        pStylesheet - The XSLT stylesheet to read.
      • getFileMappers

        public org.codehaus.plexus.components.io.filemappers.FileMapper[] getFileMappers()
        Returns a set of file mappers, which are being used to convert the generated files name.
        Returns:
        The set of file mappers to use.
      • setFileMappers

        public void setFileMappers​(org.codehaus.plexus.components.io.filemappers.FileMapper[] pFileMappers)
        Sets a set of file mappers, which are being used to convert the generated files name.
        Parameters:
        pFileMappers - The set of file mappers to use.
      • isValidating

        public boolean isValidating()
        Returns, whether the transformer should create validating XML parsers for reading XML documents. The default value is false.
        Returns:
        True, if the transformers parser will be validating. Otherwise false.
      • setValidating

        public void setValidating​(boolean pValidating)
        Sets, whether the transformer should create validating XML parsers for reading XML documents. The default value is false.
        Parameters:
        pValidating - True, if the transformers parser will be validating. Otherwise false.
      • getOutputProperties

        public NameValuePair[] getOutputProperties()
        Returns the transformers output properties.
        Returns:
        The transformers output properties.
      • setOutputProperties

        public void setOutputProperties​(NameValuePair[] pOutputProperties)
        Sets the transformers output properties.
        Parameters:
        pOutputProperties - The transformers output properties.
      • getFeatures

        public NameValuePair[] getFeatures()
        Returns the features, which should be set on the transformer factory.
        Returns:
        The features to set on the transformer factory.
      • setFeatures

        public void setFeatures​(NameValuePair[] pFeatures)
        Sets the features, which should be set on the transformer factory.
        Parameters:
        pFeatures - The features to set on the transformer factory.
      • getAttributes

        public NameValuePair[] getAttributes()
        Returns the attributes, which should be set on the transformer factory.
        Returns:
        The attributes to set on the transformer factory.
      • setAttributes

        public void setAttributes​(NameValuePair[] pAttributes)
        Sets the attributes, which should be set on the transformer factory.
        Parameters:
        pAttributes - The attributes to set on the transformer factory.
      • isXincludeAware

        public boolean isXincludeAware()
        Returns, whether the transformer should create xinclude aware XML parsers for reading XML documents. The default value is false.
        Returns:
        True for XML parsers, that are xinclude aware. Otherwise false.
      • setXincludeAware

        public void setXincludeAware​(boolean pXIncludeAware)
        Sets, whether the transformer should create xinclude aware XML parsers for reading XML documents. The default value is false.
        Parameters:
        pXIncludeAware - True for XML parsers, that are xinclude aware. Otherwise false.