Class BaseAntTask

java.lang.Object
org.apache.tools.ant.ProjectComponent
org.apache.tools.ant.Task
org.apache.rat.anttasks.BaseAntTask
All Implemented Interfaces:
Cloneable
Direct Known Subclasses:
Help, Report

public abstract class BaseAntTask extends org.apache.tools.ant.Task
Generated class to provide Ant support for standard RAT command line options. DO NOT EDIT - GENERATED FILE
  • Field Details

  • Constructor Details

    • BaseAntTask

      protected BaseAntTask()
  • Method Details

    • createName

      public static String createName(String longOpt)
    • unsupportedArgs

      public static List<String> unsupportedArgs()
    • args

      protected List<String> args()
      Gets the list of arguments prepared for the CLI code to parse.
      Returns:
      the List of arguments for the CLI command line.
    • setArg

      protected void setArg(String key, String value)
      Set a key and value into the argument list. Replaces any existing value.
      Parameters:
      key - the key for the map.
      value - the value to set.
    • getArg

      public List<String> getArg(String key)
      Get the list of values for a key.
      Parameters:
      key - the key for the map.
      Returns:
      the list of values for the key or null if not set.
    • addArg

      protected void addArg(String key, String[] value)
      Add values to the key in the argument list. empty values are ignored. If no non-empty values are present no change is made. If the key does not exist, adds it.
      Parameters:
      key - the key for the map.
      value - the array of values to set.
    • addArg

      protected void addArg(String key, String value)
      Add a value to the key in the argument list. If the key does not exist, adds it.
      Parameters:
      key - the key for the map.
      value - the value to set.
    • removeArg

      protected void removeArg(String key)
      Remove a key from the argument list.
      Parameters:
      key - the key to remove from the map.
    • setCopyright

      public void setCopyright(String copyright)
      Deprecated.
      Deprecated for removal since 0.17: Use editCopyright attribute instead.
      The copyright message to use in the license headers.
      Parameters:
      copyright - Copyright message to use in the license headers.
    • setEditCopyright

      public void setEditCopyright(String editCopyright)
      The copyright message to use in the license headers. Usually in the form of "Copyright 2008 Foo". Only valid with editLicense attribute
      Parameters:
      editCopyright - Copyright message to use in the license headers.
    • setForce

      public void setForce(boolean force)
      Deprecated.
      Deprecated for removal since 0.17: Use editOverwrite attribute instead.
      Forces any changes in files to be written directly to the source files so that new files are not created.
      Parameters:
      force - The state
    • setEditOverwrite

      public void setEditOverwrite(boolean editOverwrite)
      Forces any changes in files to be written directly to the source files so that new files are not created. Only valid with editLicense attribute.
      Parameters:
      editOverwrite - The state
    • setAddLicense

      public void setAddLicense(boolean addLicense)
      Deprecated.
      Deprecated for removal since 0.17: Use editLicense attribute instead.
      Add the default license header to any file with an unknown license that is not in the exclusion list.
      Parameters:
      addLicense - The state
    • setEditLicense

      public void setEditLicense(boolean editLicense)
      Add the default license header to any file with an unknown license that is not in the exclusion list. By default new files will be created with the license header, to force the modification of existing files use the editOverwrite attribute option.
      Parameters:
      editLicense - The state
    • setConfigurationNoDefaults

      public void setConfigurationNoDefaults(boolean configurationNoDefaults)
      Ignore default configuration.
      Parameters:
      configurationNoDefaults - The state
    • setNoDefaultLicenses

      public void setNoDefaultLicenses(boolean noDefaultLicenses)
      Deprecated.
      Deprecated for removal since 0.17: Use configurationNoDefaults attribute instead.
      Ignore default configuration.
      Parameters:
      noDefaultLicenses - The state
    • setExcludeFile

      public void setExcludeFile(String excludeFile)
      Deprecated.
      Deprecated for removal since 0.17: Use inputExcludeFile attribute instead.
      Reads <Expression> entries from a file. Entries will be excluded from processing. Argument should be a File. (See Argument Types for clarification)
      Parameters:
      excludeFile - <Expression> entries from a file.
    • setInputExcludeSize

      public void setInputExcludeSize(String inputExcludeSize)
      Excludes files with sizes less than the given argument. Argument should be a Integer. (See Argument Types for clarification)
      Parameters:
      inputExcludeSize - Files with sizes less than the given argument.
    • setIncludesFile

      public void setIncludesFile(String includesFile)
      Deprecated.
      Deprecated for removal since 0.17: Use inputIncludeFile attribute instead.
      Reads <Expression> entries from a file. Entries will be excluded from processing. Argument should be a File. (See Argument Types for clarification)
      Parameters:
      includesFile - <Expression> entries from a file.
    • setScanHiddenDirectories

      public void setScanHiddenDirectories(boolean scanHiddenDirectories)
      Deprecated.
      Deprecated for removal since 0.17: Use <inputIncludeStd> with 'HIDDEN_DIR' argument instead.
      Scans hidden directories.
      Parameters:
      scanHiddenDirectories - The state
    • setOutputStyle

      public void setOutputStyle(String outputStyle)
      XSLT stylesheet to use when creating the report. Either an external xsl file may be specified or one of the internal named sheets. Argument should be a StyleSheet. (See Argument Types for clarification)
      Parameters:
      outputStyle - Stylesheet to use when creating the report.
    • setStylesheet

      public void setStylesheet(String stylesheet)
      Deprecated.
      Deprecated for removal since 0.17: Use outputStyle attribute instead.
      XSLT stylesheet to use when creating the report. Argument should be a StyleSheet. (See Argument Types for clarification)
      Parameters:
      stylesheet - Stylesheet to use when creating the report.
    • setXml

      public void setXml(boolean xml)
      Deprecated.
      Deprecated for removal since 0.17: Use outputStyle attribute with the 'xml' argument instead.
      forces XML output rather than the textual report.
      Parameters:
      xml - The state
    • setOutputLicenses

      public void setOutputLicenses(String outputLicenses)
      List the defined licenses. Argument should be a LicenseFilter. (See Argument Types for clarification)
      Parameters:
      outputLicenses - The defined licenses.
    • setListLicenses

      public void setListLicenses(String listLicenses)
      Deprecated.
      Deprecated for removal since 0.17: Use outputLicenses attribute instead.
      List the defined licenses. Argument should be a LicenseFilter. (See Argument Types for clarification)
      Parameters:
      listLicenses - The defined licenses.
    • setOutputFamilies

      public void setOutputFamilies(String outputFamilies)
      List the defined license families. Argument should be a LicenseFilter. (See Argument Types for clarification)
      Parameters:
      outputFamilies - The defined license families.
    • setListFamilies

      public void setListFamilies(String listFamilies)
      Deprecated.
      Deprecated for removal since 0.17: Use outputFamilies attribute instead.
      List the defined license families. Argument should be a LicenseFilter. (See Argument Types for clarification)
      Parameters:
      listFamilies - The defined license families.
    • setDryRun

      public void setDryRun(boolean dryRun)
      If set do not update the files but generate the reports.
      Parameters:
      dryRun - The state
    • setOut

      public void setOut(String out)
      Deprecated.
      Deprecated for removal since 0.17: Use outputFile attribute instead.
      Define the output file where to write a report to. Argument should be a File. (See Argument Types for clarification)
      Parameters:
      out - The output file where to write a report to.
    • setOutputFile

      public void setOutputFile(String outputFile)
      Define the output file where to write a report to. Argument should be a File. (See Argument Types for clarification)
      Parameters:
      outputFile - The output file where to write a report to.
    • setOutputArchive

      public void setOutputArchive(String outputArchive)
      Specifies the level of detail in ARCHIVE file reporting. Argument should be a ProcessingType. (See Argument Types for clarification)
      Parameters:
      outputArchive - The level of detail in ARCHIVE file reporting.
    • setOutputStandard

      public void setOutputStandard(String outputStandard)
      Specifies the level of detail in STANDARD file reporting. Argument should be a ProcessingType. (See Argument Types for clarification)
      Parameters:
      outputStandard - The level of detail in STANDARD file reporting.
    • setHelpLicenses

      public void setHelpLicenses(boolean helpLicenses)
      Print information about registered licenses.
      Parameters:
      helpLicenses - The state
    • createConfig

      public BaseAntTask.Config createConfig()
      File names for system configuration.
    • createLicenses

      public BaseAntTask.Licenses createLicenses()
      Deprecated.
      Deprecated for removal since 0.17: Use <config> instead.
      File names for system configuration.
    • createLicensesApproved

      public BaseAntTask.LicensesApproved createLicensesApproved()
      A comma separated list of approved License IDs. These licenses will be added to the list of approved licenses.
    • createLicenseFamiliesApproved

      public BaseAntTask.LicenseFamiliesApproved createLicenseFamiliesApproved()
      A comma separated list of approved license family IDs. These license families will be added to the list of approved license families.
    • createLicensesDenied

      public BaseAntTask.LicensesDenied createLicensesDenied()
      A comma separated list of denied License IDs. These licenses will be removed from the list of approved licenses. Once licenses are removed they can not be added back.
    • createLicenseFamiliesDenied

      public BaseAntTask.LicenseFamiliesDenied createLicenseFamiliesDenied()
      A comma separated list of denied License family IDs. These license families will be removed from the list of approved licenses. Once license families are removed they can not be added back.
    • createCounterMax

      public BaseAntTask.CounterMax createCounterMax()
      The acceptable maximum number for the specified counter. A value of '-1' specifies an unlimited number.
    • createCounterMin

      public BaseAntTask.CounterMin createCounterMin()
      The minimum number for the specified counter.
    • createExclude

      public BaseAntTask.Exclude createExclude()
      Deprecated.
      Deprecated for removal since 0.17: Use <inputExclude> instead.
      Excludes files matching <Expression>.
    • createInputExclude

      public BaseAntTask.InputExclude createInputExclude()
      Excludes files matching <Expression>.
    • createInputInclude

      public BaseAntTask.InputInclude createInputInclude()
      Includes files matching <Expression>. Will override excluded files.
    • createInclude

      public BaseAntTask.Include createInclude()
      Deprecated.
      Deprecated for removal since 0.17: Use <inputInclude> instead.
      Includes files matching <Expression>. Will override excluded files.
    • createInputExcludeParsedScm

      public BaseAntTask.InputExcludeParsedScm createInputExcludeParsedScm()
      Parse SCM based exclusion files to exclude specified files and directories.