javax.cim
Class CIMArgument<E>

java.lang.Object
  extended by javax.cim.CIMElement
      extended by javax.cim.CIMArgument<E>
All Implemented Interfaces:
Serializable, Comparable<CIMElement>

public class CIMArgument<E>
extends CIMElement
implements Serializable

This class represents an instance of a CIMParameter used for a method invocation. A CIMArgument has a name, data type and value. A CIMArgument corresponds to a CIMParameter defined for a CIMMethod.

Since:
JSR48 1.0.0
See Also:
CIMParameter, Serialized Form

Constructor Summary
CIMArgument(String name, CIMDataType type, E value)
          Constructs a CIMArgument to be used for method invocations.
 
Method Summary
 boolean equals(Object obj)
          Compares this object against the specified object.
 CIMDataType getDataType()
          Returns the CIMDataType for this CIM Element.
 E getValue()
          Returns the value for this CIM Element.
 String toString()
          Returns a String representation of the CIMElement This method is intended to be used only for debugging purposes, and the format of the returned string may vary between implementations.
 
Methods inherited from class javax.cim.CIMElement
compareTo, getName, hashCode
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

CIMArgument

public CIMArgument(String name,
                   CIMDataType type,
                   E value)
Constructs a CIMArgument to be used for method invocations. A CIMArgument corresponds to a CIMParameter. For each CIMParameter being populated during a method invocation a CIMArgument object must be created.

Parameters:
name - Name of the CIM argument
type - CIMDataType of the argument
value - value of the argument
Throws:
IllegalArgumentException - If the value does not match the type.
See Also:
CIMParameter
Method Detail

equals

public boolean equals(Object obj)
Compares this object against the specified object. The result is true if and only if the argument is not null and is a CIMValuedObject that represents the same name, type and value as this object.

Parameters:
obj - - the object to compare with.
Returns:
true if the objects are the same; false otherwise.

getValue

public E getValue()
Returns the value for this CIM Element.

Returns:
Object The value of the CIM Element. null is a valid value.

toString

public String toString()
Returns a String representation of the CIMElement This method is intended to be used only for debugging purposes, and the format of the returned string may vary between implementations. The returned string may be empty but may not be null.

Overrides:
toString in class CIMElement
Returns:
string representation of this element

getDataType

public CIMDataType getDataType()
Returns the CIMDataType for this CIM Element.

Returns:
CIMDataType of this CIM element.


Copyright © 2002-2008 WBEM Solutions, Inc. All Rights Reserved.