org.jwarp.service.param
Class Parameter

java.lang.Object
  |
  +--org.jwarp.service.param.Property
        |
        +--org.jwarp.service.param.Parameter
All Implemented Interfaces:
IParameter, IProperty
Direct Known Subclasses:
InParameter

public class Parameter
extends Property
implements IParameter

Class implementing a parameter.


Field Summary
(package private)  IParameterDescription metadata
          The parameter description.
 
Fields inherited from class org.jwarp.service.param.Property
name, value
 
Constructor Summary
Parameter(IParameterDescription metadata, java.lang.Object value)
          Constructs a new parameter given the meta data and the value.
Parameter(java.lang.String name, java.lang.Object value)
          Constructs a new parameter given the meta data and the value.
 
Method Summary
 IParameterDescription getMetaData()
          Returns the parameter's metadata.
 java.lang.String getName()
          Returns the parameters name (taken from the metadata).
 
Methods inherited from class org.jwarp.service.param.Property
getAsBoolean, getAsDouble, getAsFloat, getAsInteger, getAsLong, getAsString, getValue, getValue, setName, setValue
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.jwarp.service.param.IProperty
getAsBoolean, getAsDouble, getAsFloat, getAsInteger, getAsLong, getAsString, getValue, getValue, setValue
 

Field Detail

metadata

IParameterDescription metadata
The parameter description.
Constructor Detail

Parameter

public Parameter(java.lang.String name,
                 java.lang.Object value)
          throws ParameterException
Constructs a new parameter given the meta data and the value. The value is validated with the meta data's validator, so a ParameterException is thrown if the validation failed. The parameter type will be PARAMTYPE_INOUT.
Parameters:
metadata - The parameter's meta data
value - The parameters value
Throws:
ParameterException - If the validation of the value fails.

Parameter

public Parameter(IParameterDescription metadata,
                 java.lang.Object value)
          throws ParameterException
Constructs a new parameter given the meta data and the value. The value is validated with the meta data's validator, so a ParameterException is thrown if the validation failed. The parameter type will be PARAMTYPE_INOUT.
Parameters:
metadata - The parameter's meta data
value - The parameters value
Throws:
ParameterException - If the validation of the value fails.
Method Detail

getName

public java.lang.String getName()
Returns the parameters name (taken from the metadata).
Specified by:
getName in interface IProperty
Overrides:
getName in class Property
Returns:
The parameters name

getMetaData

public IParameterDescription getMetaData()
Returns the parameter's metadata.
Specified by:
getMetaData in interface IParameter
Returns:
The meta data.

©   O R C A   S y s t e m s