Tuscany DAS for Relational Databases

org.apache.tuscany.das.rdb.impl
Class ParameterImpl

java.lang.Object
  extended by org.apache.tuscany.das.rdb.impl.ParameterImpl
All Implemented Interfaces:
Parameter

public class ParameterImpl
extends java.lang.Object
implements Parameter


Field Summary
 
Fields inherited from interface org.apache.tuscany.das.rdb.Parameter
IN, IN_OUT, OUT
 
Constructor Summary
ParameterImpl()
           
ParameterImpl(int index)
           
ParameterImpl(java.lang.String name)
           
 
Method Summary
 Converter getConverter()
          TODO Not sure this is is needed.
 int getDirection()
           
 int getIndex()
           
 java.lang.String getName()
           
 commonj.sdo.Type getType()
           
 java.lang.Object getValue()
           
 void setConverter(Converter converter)
          TODO Not sure this method is needed.
 void setDirection(int direction)
          Parameters are typically IN and this is the default.
 void setIndex(int index)
          Set the index of the parameter.
 void setName(java.lang.String name)
          Sets the name of the parameter
 void setType(commonj.sdo.Type type)
          A parameter has a type in terms of SDO2 DataTypes.
 void setValue(java.lang.Object value)
          Sets the value of the parameter.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ParameterImpl

public ParameterImpl()

ParameterImpl

public ParameterImpl(java.lang.String name)

ParameterImpl

public ParameterImpl(int index)
Method Detail

setType

public void setType(commonj.sdo.Type type)
Description copied from interface: Parameter
A parameter has a type in terms of SDO2 DataTypes. Legal values are provided in SDODataTypes

Explicit definition of type is required only for OUT parameters of stored procedures commands

Specified by:
setType in interface Parameter

setIndex

public void setIndex(int index)
Description copied from interface: Parameter
Set the index of the parameter. For example, if a SQL statement requires two parameters, the first one has an index of one.

Specified by:
setIndex in interface Parameter
Parameters:
index - The index of the parameter

setName

public void setName(java.lang.String name)
Description copied from interface: Parameter
Sets the name of the parameter

Specified by:
setName in interface Parameter
Parameters:
name - the parameter name

setValue

public void setValue(java.lang.Object value)
Description copied from interface: Parameter
Sets the value of the parameter. All IN and IN_OUT parameters must be set beore a command can be executed.

Specified by:
setValue in interface Parameter
Parameters:
value - The value for the parameter

setDirection

public void setDirection(int direction)
Description copied from interface: Parameter
Parameters are typically IN and this is the default. A parameter's direction must be set when the parameter is OUT or IN_OUT.

Specified by:
setDirection in interface Parameter
Parameters:
direction - the parameters direction

getType

public commonj.sdo.Type getType()
Specified by:
getType in interface Parameter
Returns:
the type of the paramater in terms of SDODataTypes

getIndex

public int getIndex()
Specified by:
getIndex in interface Parameter
Returns:
the index of the parameter

getName

public java.lang.String getName()
Specified by:
getName in interface Parameter
Returns:
the name of the parameter

getValue

public java.lang.Object getValue()
Specified by:
getValue in interface Parameter
Returns:
the value of the parameter

getDirection

public int getDirection()
Specified by:
getDirection in interface Parameter
Returns:
the direction of the parameter

setConverter

public void setConverter(Converter converter)
Description copied from interface: Parameter
TODO Not sure this method is needed.

Specified by:
setConverter in interface Parameter

getConverter

public Converter getConverter()
Description copied from interface: Parameter
TODO Not sure this is is needed.

Specified by:
getConverter in interface Parameter
Returns:

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

Tuscany DAS for Relational Databases

-