org.jdtaus.core.container
Class Argument

java.lang.Object
  extended by org.jdtaus.core.container.ModelObject
      extended by org.jdtaus.core.container.Argument
All Implemented Interfaces:
Serializable, Cloneable

public class Argument
extends ModelObject
implements Cloneable, Serializable

Argument meta-data.

An argument consists of the properties index, name and type. Property index holds the index of the argument in a list of arguments. Property name holds the name uniquely identifying the argument in a set of arguments. Property type holds the type of the argument.

Version:
$Id: Argument.java 8044 2009-07-02 01:29:05Z schulte2005 $
Author:
Christian Schulte
See Also:
Serialized Form

Field Summary
static int TYPE_DATE
          Constant for property type.
static int TYPE_NUMBER
          Constant for property type.
static int TYPE_TEXT
          Constant for property type.
static int TYPE_TIME
          Constant for property type.
 
Constructor Summary
Argument()
           
 
Method Summary
 Object clone()
          Creates and returns a copy of this object.
 boolean equals(Object o)
          Indicates whether some other object is equal to this one by comparing the values of all properties.
 int getIndex()
          Gets the index of the argument.
 String getName()
          Gets the name of the argument.
 int getType()
          Gets the type of the argument.
 int hashCode()
          Returns a hash code value for this object.
 void setIndex(int value)
          Setter for property index.
 void setName(String value)
          Setter for property name.
 void setType(int value)
          Setter for property type.
 String toString()
          Returns a string representation of the object.
 
Methods inherited from class org.jdtaus.core.container.ModelObject
getDocumentation, getModelVersion, setDocumentation, setModelVersion
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

TYPE_DATE

public static final int TYPE_DATE
Constant for property type.

See Also:
Constant Field Values

TYPE_NUMBER

public static final int TYPE_NUMBER
Constant for property type.

See Also:
Constant Field Values

TYPE_TEXT

public static final int TYPE_TEXT
Constant for property type.

See Also:
Constant Field Values

TYPE_TIME

public static final int TYPE_TIME
Constant for property type.

See Also:
Constant Field Values
Constructor Detail

Argument

public Argument()
Method Detail

clone

public Object clone()
Creates and returns a copy of this object. This method performs a "shallow copy" of this object, not a "deep copy" operation.

Overrides:
clone in class Object
Returns:
a clone of this instance.

equals

public boolean equals(Object o)
Indicates whether some other object is equal to this one by comparing the values of all properties.

Overrides:
equals in class Object
Parameters:
o - the reference object with which to compare.
Returns:
true if this object is the same as o; false otherwise.

getIndex

public int getIndex()
Gets the index of the argument.

Returns:
the index of the argument.

getName

public String getName()
Gets the name of the argument.

Returns:
the name of the argument.

getType

public int getType()
Gets the type of the argument.

Returns:
the type of the argument.

hashCode

public int hashCode()
Returns a hash code value for this object.

Overrides:
hashCode in class Object
Returns:
a hash code value for this object.

setIndex

public void setIndex(int value)
Setter for property index.

Parameters:
value - the new index of the argument.

setName

public void setName(String value)
Setter for property name.

Parameters:
value - the new name of the argument.

setType

public void setType(int value)
Setter for property type.

Parameters:
value - the new type of the argument.
Throws:
IllegalArgumentException - if value is not equal to one of the constants TYPE_NUMBER, TYPE_DATE, TYPE_TIME or TYPE_TEXT.

toString

public String toString()
Returns a string representation of the object.

Overrides:
toString in class Object
Returns:
a string representation of the object.


Copyright © 2005-2009 jDTAUS. All Rights Reserved.