org.apache.avalon.composition.data
Class Mode

java.lang.Object
  extended byorg.apache.avalon.composition.data.Mode
All Implemented Interfaces:
Serializable

public class Mode
extends Object
implements Serializable

The Mode class declares the EXPLICIT, PACKAGED or IMPLICIT mode of creation of a profile.

Version:
$Revision: 1.1.1.1 $ $Date: 2003/09/24 09:31:08 $
Author:
Avalon Development Team
See Also:
Profile, Serialized Form

Field Summary
static Mode EXPLICIT
          Constant indicating that the profile was explicitly declared under an assembly directive.
static int EXPLICIT_VALUE
          Constant indicating that the profile was explicitly declared under an assembly directive.
static Mode IMPLICIT
          Constant indicating that the profile was implicitly created.
static int IMPLICIT_VALUE
          Constant indicating that the profile was implicitly created.
static Mode PACKAGED
          Constant indicating that the profile was created based on a profile packaged with the type.
static int PACKAGED_VALUE
          Constant indicating that the profile was created based on a profile packaged with the type.
 
Constructor Summary
Mode(int mode)
          Creation of a new mode value.
 
Method Summary
 boolean equals(Object object)
          Compare a supplied object for equality.
 int getValue()
          The supplied argument.
static String modeToString(int mode)
          Returns a string representation of a mode value.
 String toString()
          Return a string representatio of the mode.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

IMPLICIT_VALUE

public static final int IMPLICIT_VALUE
Constant indicating that the profile was implicitly created.

See Also:
Constant Field Values

PACKAGED_VALUE

public static final int PACKAGED_VALUE
Constant indicating that the profile was created based on a profile packaged with the type.

See Also:
Constant Field Values

EXPLICIT_VALUE

public static final int EXPLICIT_VALUE
Constant indicating that the profile was explicitly declared under an assembly directive.

See Also:
Constant Field Values

IMPLICIT

public static final Mode IMPLICIT
Constant indicating that the profile was implicitly created.


PACKAGED

public static final Mode PACKAGED
Constant indicating that the profile was created based on a profile packaged with the type.


EXPLICIT

public static final Mode EXPLICIT
Constant indicating that the profile was explicitly declared under an assembly directive.

Constructor Detail

Mode

public Mode(int mode)
Creation of a new mode value.

Parameters:
mode - the int value of the mode.
Method Detail

modeToString

public static String modeToString(int mode)
Returns a string representation of a mode value.

Parameters:
mode - the mode value
Returns:
the string representation

getValue

public int getValue()
The supplied argument.

Returns:
the mode value

toString

public String toString()
Return a string representatio of the mode.

Returns:
String the string value

equals

public boolean equals(Object object)
Compare a supplied object for equality.

Parameters:
object - the other object
Returns:
TRUE if the supplied mode is equivalent to this mode.


Copyright © Apache Software Foundation. All Rights Reserved.