Class Activation

java.lang.Object
org.apache.maven.model.Activation
All Implemented Interfaces:
Serializable, Cloneable, InputLocationTracker

public class Activation extends Object implements Serializable, Cloneable, InputLocationTracker
The conditions within the build runtime environment which will trigger the automatic inclusion of the build profile. Multiple conditions can be defined, which must be all satisfied to activate the profile.
Version:
$Revision$ $Date$
See Also:
  • Constructor Summary Link icon

    Constructors
    Constructor
    Description
     
  • Method Summary Link icon

    Modifier and Type
    Method
    Description
    Method clone.
    Get specifies that this profile will be activated based on existence of a file.
    Get specifies that this profile will be activated when a matching JDK is detected.
    Gets the location of the specified field in the input source.
    Get specifies that this profile will be activated when matching operating system attributes are detected.
    Get specifies that this profile will be activated when this property is specified.
    boolean
    Get if set to true, this profile will be active unless another profile in this pom is activated using the command line -P option or by one of that profile's activators.
    void
    setActiveByDefault(boolean activeByDefault)
    Set if set to true, this profile will be active unless another profile in this pom is activated using the command line -P option or by one of that profile's activators.
    void
    Set specifies that this profile will be activated based on existence of a file.
    void
    Set specifies that this profile will be activated when a matching JDK is detected.
    void
    Sets the location of the specified field.
    void
    Set specifies that this profile will be activated when matching operating system attributes are detected.
    void
     
    void
    Set specifies that this profile will be activated when this property is specified.

    Methods inherited from class java.lang.Object Link icon

    equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details Link icon

    • Activation Link icon

      public Activation()
  • Method Details Link icon

    • clone Link icon

      public Activation clone()
      Method clone.
      Overrides:
      clone in class Object
      Returns:
      Activation
    • getFile Link icon

      public ActivationFile getFile()
      Get specifies that this profile will be activated based on existence of a file.
      Returns:
      ActivationFile
    • getJdk Link icon

      public String getJdk()
      Get specifies that this profile will be activated when a matching JDK is detected. For example, 1.4 only activates on JDKs versioned 1.4, while !1.4 matches any JDK that is not version 1.4. Ranges are supported too: [1.5,) activates when the JDK is 1.5 minimum.
      Returns:
      String
    • getLocation Link icon

      public InputLocation getLocation(Object key)
      Description copied from interface: InputLocationTracker
      Gets the location of the specified field in the input source.
      Specified by:
      getLocation in interface InputLocationTracker
      Parameters:
      key - a key object.
      Returns:
      InputLocation
    • getOs Link icon

      public ActivationOS getOs()
      Get specifies that this profile will be activated when matching operating system attributes are detected.
      Returns:
      ActivationOS
    • setLocation Link icon

      public void setLocation(Object key, InputLocation location)
      Description copied from interface: InputLocationTracker
      Sets the location of the specified field.
      Specified by:
      setLocation in interface InputLocationTracker
      Parameters:
      key - a key object.
      location - a location object.
    • setOtherLocation Link icon

      public void setOtherLocation(Object key, InputLocation location)
      Parameters:
      key - a key object.
      location - a location object.
    • getProperty Link icon

      public ActivationProperty getProperty()
      Get specifies that this profile will be activated when this property is specified.
      Returns:
      ActivationProperty
    • isActiveByDefault Link icon

      public boolean isActiveByDefault()
      Get if set to true, this profile will be active unless another profile in this pom is activated using the command line -P option or by one of that profile's activators.
      Returns:
      boolean
    • setActiveByDefault Link icon

      public void setActiveByDefault(boolean activeByDefault)
      Set if set to true, this profile will be active unless another profile in this pom is activated using the command line -P option or by one of that profile's activators.
      Parameters:
      activeByDefault - a activeByDefault object.
    • setFile Link icon

      public void setFile(ActivationFile file)
      Set specifies that this profile will be activated based on existence of a file.
      Parameters:
      file - a file object.
    • setJdk Link icon

      public void setJdk(String jdk)
      Set specifies that this profile will be activated when a matching JDK is detected. For example, 1.4 only activates on JDKs versioned 1.4, while !1.4 matches any JDK that is not version 1.4. Ranges are supported too: [1.5,) activates when the JDK is 1.5 minimum.
      Parameters:
      jdk - a jdk object.
    • setOs Link icon

      public void setOs(ActivationOS os)
      Set specifies that this profile will be activated when matching operating system attributes are detected.
      Parameters:
      os - a os object.
    • setProperty Link icon

      public void setProperty(ActivationProperty property)
      Set specifies that this profile will be activated when this property is specified.
      Parameters:
      property - a property object.