Package org.apache.torque.generator.configuration.paths

# Klasse CustomProjectPaths

java.lang.Object
org.apache.torque.generator.configuration.paths.CustomProjectPaths

Alle implementierten Schnittstellen:
  `ProjectPaths`

public class CustomProjectPaths extends Object implements ProjectPaths
Implementation of ProjectPaths with custom paths.

- ## Konstruktorübersicht

  Konstruktoren
  Konstruktor
  Beschreibung
  `CustomProjectPaths(File configurationDir, String configurationPackage, File sourceDir, Map<String,File> outputDirectoryMap, File workDir, File cacheDir)`
  Constructor.
  `CustomProjectPaths(ProjectPaths toCopy)`
  Copy-constructor.

- ## Methodenübersicht

  Modifizierer und Typ
  Methode
  Beschreibung
  `void`
  `checkInit()`
  Checks whether the current settings are valid.
  `File`
  `getCacheDirectory()`
  Returns the cache directory where the torque generator can store internal files, relative to the project root.
  `String`
  `getConfigurationPackage()`
  Returns the root package of the Torque generator files.
  `File`
  `getConfigurationPath()`
  Returns the root directory for the Torque generator files, relative to the project root.
  `File`
  `getDefaultSourcePath()`
  Returns the default directory for the source files, relative to the project root.
  `File`
  `getOutputDirectory(String outputDirKey)`
  Returns the output directory for a given output directory key.
  `Map<String,File>`
  `getOutputDirectoryMap()`
  Returns the output directory map which contains the mapping from output directory key to output directory.
  `File`
  `getWorkDirectory()`
  Returns the work directory where the torque generator can store internal files, relative to the project root.
  `void`
  `setCacheDir(File cacheDir)`
  Sets the cache directory where the torque generator can store internal files, relative to the current directory, or absolute.
  `void`
  `setConfigurationDir(File configurationDir)`
  Sets the root directory for the Torque generator configuration files, absolute or relative to the project root.
  `void`
  `setConfigurationPackage(String configurationPackage)`
  Sets the root package for the Torque generator files, relative to the project root.
  `void`
  `setOutputDirectory(String outputDirKey, File outputDir)`
  Sets the output directory for a given output directory key.
  `void`
  `setOutputDirectoryMap(Map<String,File> outputDirectoryMap)`
  Sets the contents of the output directory map.
  `void`
  `setSourceDir(File sourceDir)`
  Sets the default directory for the source files, relative to the current directory, or absolute.
  `void`
  `setWorkDir(File workDir)`
  Sets the work directory where the torque generator can store internal files, relative to the current directory, or absolute.
  `String`
  `toString()`

  ### Von Klasse geerbte Methoden java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- ## Konstruktordetails

  - ### CustomProjectPaths

    public CustomProjectPaths(ProjectPaths toCopy)
    Copy-constructor.
    Parameter:
      `toCopy` - the default project paths to copy, not null.
    Löst aus:
      `NullPointerException` - if toCopy is null.

  - ### CustomProjectPaths

    public CustomProjectPaths(File configurationDir, String configurationPackage, File sourceDir, Map<String,File> outputDirectoryMap, File workDir, File cacheDir)
    Constructor.
    Parameter:
      `configurationDir` - the configuration directory for the Torque generator configuration files, or null if the configuration files are loaded from the classpath.
      `configurationPackage` - the package containing the Torque generator configuration files, or null if the configuration files are loaded from the file system.
      `sourceDir` - the default directory for the source files, or null.
      `outputDirectoryMap` - The output directories for the files, keyed by the output directory key. The directory with the key null is the default output directory.
      `workDir` - work directory where the torque generator can store internal files.
      `cacheDir` - cache directory where the torque generator can store internal files.

- ## Methodendetails

  - ### setConfigurationDir

    public void setConfigurationDir(File configurationDir)
    Sets the root directory for the Torque generator configuration files, absolute or relative to the project root.
    Parameter:
      `configurationDir` - the configuration directory for the Torque generator configuration files, null to invalidate the current setting.

  - ### setConfigurationPackage

    public void setConfigurationPackage(String configurationPackage)
    Sets the root package for the Torque generator files, relative to the project root.
    Parameter:
      `configurationPackage` - the configuration root package for the Torque generator files.

  - ### setSourceDir

    public void setSourceDir(File sourceDir)
    Sets the default directory for the source files, relative to the current directory, or absolute. "Default" means that the setting can be overridden in a unit of generation.
    Parameter:
      `sourceDir` - the default directory for the source files, null to invalidate the current setting.

  - ### setOutputDirectory

    public void setOutputDirectory(String outputDirKey, File outputDir)
    Sets the output directory for a given output directory key.
    Parameter:
      `outputDirKey` - the output directory key, or null for the default output directory.
      `outputDir` - the output directory for the key, relative to the current directory, or absolute. Use null to remove the output directory for the key.

  - ### setOutputDirectoryMap

    public void setOutputDirectoryMap(Map<String,File> outputDirectoryMap)
    Sets the contents of the output directory map. The directory with the key null is the default output directory.
    Parameter:
      `outputDirectoryMap` - the new output directory map.

  - ### setWorkDir

    public void setWorkDir(File workDir)
    Sets the work directory where the torque generator can store internal files, relative to the current directory, or absolute.
    Parameter:
      `workDir` - the work directory for internal files, null to invalidate the current setting.

  - ### setCacheDir

    public void setCacheDir(File cacheDir)
    Sets the cache directory where the torque generator can store internal files, relative to the current directory, or absolute.
    Parameter:
      `cacheDir` - the cache directory for internal files, null to invalidate the current setting.

  - ### getConfigurationPath

    public File getConfigurationPath()
    Returns the root directory for the Torque generator files, relative to the project root.
    Angegeben von:
      `getConfigurationPath` in Schnittstelle `ProjectPaths`
    Gibt zurück:
      the directory for the Torque generator files, not null.
    Löst aus:
      `IllegalStateException` - if one of the required parameters is not set.

  - ### getConfigurationPackage

    public String getConfigurationPackage()
    Returns the root package of the Torque generator files.
    Angegeben von:
      `getConfigurationPackage` in Schnittstelle `ProjectPaths`
    Gibt zurück:
      the root package of the Torque generator files.
    Löst aus:
      `IllegalStateException` - if one of the required parameters is not set.

  - ### getDefaultSourcePath

    public File getDefaultSourcePath()
    Returns the default directory for the source files, relative to the project root. "Default" means that the setting can be overridden in a unit of generation.
    Angegeben von:
      `getDefaultSourcePath` in Schnittstelle `ProjectPaths`
    Gibt zurück:
      the directory for the source files, not null.
    Löst aus:
      `IllegalStateException` - if one of the required parameters is not set.

  - ### getOutputDirectory

    public File getOutputDirectory(String outputDirKey)
    Returns the output directory for a given output directory key.
    Angegeben von:
      `getOutputDirectory` in Schnittstelle `ProjectPaths`
    Parameter:
      `outputDirKey` - the output directory key, or null for the default output directory.
    Gibt zurück:
      the output directory for the key, relative to the current directory, or absolute, not null.
    Löst aus:
      `IllegalStateException` - if one of the required parameters is not set.
      `IllegalArgumentException` - if the outputDirKey is unknown.

  - ### getOutputDirectoryMap

    public Map<String,File> getOutputDirectoryMap()
    Returns the output directory map which contains the mapping from output directory key to output directory.
    Angegeben von:
      `getOutputDirectoryMap` in Schnittstelle `ProjectPaths`
    Gibt zurück:
      the mutable output directory map, not null, contains at least a mapping for the key null.
    Löst aus:
      `IllegalStateException` - if one of the required parameters is not set.

  - ### getWorkDirectory

    public File getWorkDirectory()
    Returns the work directory where the torque generator can store internal files, relative to the project root.
    Angegeben von:
      `getWorkDirectory` in Schnittstelle `ProjectPaths`
    Gibt zurück:
      the work directory where the torque generator can store internal files, not null.
    Löst aus:
      `IllegalStateException` - if one of the required parameters is not set.

  - ### getCacheDirectory

    public File getCacheDirectory()
    Returns the cache directory where the torque generator can store internal files, relative to the project root.
    Angegeben von:
      `getCacheDirectory` in Schnittstelle `ProjectPaths`
    Gibt zurück:
      the cache directory where the torque generator can store internal files, not null.
    Löst aus:
      `IllegalStateException` - if one of the required parameters is not set.

  - ### checkInit

    public void checkInit()
    Checks whether the current settings are valid. It is checked whether all necessary informations are set. If not, an IllegalStateException is thrown.
    Löst aus:
      `IllegalStateException` - if the current settings are valid, false otherwise.

  - ### toString

    public String toString()
    Setzt außer Kraft:
      `toString` in Klasse `Object`