Extension SDK 9.0.5

oracle.jdeveloper.webservices.util
Class Parameter

java.lang.Object
  extended byoracle.jdeveloper.webservices.util.Parameter

public class Parameter
extends java.lang.Object

Parameter is a data model that stores information about a parameter of a PL/SQL program unit. The information held in Parameter is the type of the parameter, its IN/OUT direction and whether its type is a PL/SQL built-in.


Field Summary
static java.lang.String DIRECTION_IN
          Constants describing the IN/OUT class of the parameter.
static java.lang.String DIRECTION_IN_OUT
           
static java.lang.String DIRECTION_OUT
           
 
Constructor Summary
Parameter()
          Default constructor provided to support Object2Dom marshalling.
Parameter(java.lang.String direction, java.lang.String type)
          Create a new parameter with the given direction and type.
Parameter(java.lang.String direction, java.lang.String plsType, java.lang.String dataType, java.lang.String objType, java.lang.String subType, java.lang.String typeOwner, java.sql.Connection dbConn, java.lang.String dbConnName)
          Create a new parameter with the given direction and type.
 
Method Summary
 void addSubParameter(Parameter subParam)
          Add a sub-parameter to this parameter.
 boolean canTypeBeMapped(oracle.jdevimpl.webservices.util.PLSQLJavaTypeMap plsqlToJava, oracle.jdevimpl.webservices.util.JavaXSDTypeMap javaToXSD, java.util.Map typesValidated)
          Determine whether the type of this parameter can be serialised in XML once JPublisher has mapped it to a Java type.
 java.lang.String getDataType()
          Accessor method provided to support Object2Dom marshalling.
 java.lang.String getDBConnName()
          Accessor method provided to support Object2Dom marshalling.
 java.lang.String getDeclaredIn()
          Accessor method provided to support Object2Dom marshalling.
 java.lang.String getDirection()
           
 java.lang.String getQualifiedType()
           
 java.util.List getSubParameters()
          Accessor method provided to support Object2Dom marshalling.
 java.lang.String getType()
          Accessor method provided to support Object2Dom marshalling.
 java.lang.String getTypeOwner()
          Accessor method provided to support Object2Dom marshalling.
 java.lang.String getXSDType(oracle.jdevimpl.webservices.util.PLSQLJavaTypeMap plsqlToJava, oracle.jdevimpl.webservices.util.JavaXSDTypeMap javaToXSD)
          Determine and return the equivalent XSD type for this parameter.
 boolean isPlsqlType()
          Accessor method provided to support Object2Dom marshalling.
 void setDataType(java.lang.String dataType)
          Accessor method provided to support Object2Dom marshalling.
 void setDBConnName(java.lang.String dbConnName)
          Accessor method provided to support Object2Dom marshalling.
 void setDeclaredIn(java.lang.String declaredIn)
          Accessor method provided to support Object2Dom marshalling.
 void setDirection(java.lang.String direction)
          Accessor method provided to support Object2Dom marshalling.
 void setPlsqlType(boolean plsqlType)
          Accessor method provided to support Object2Dom marshalling.
 void setSubParameters(java.util.List subParameters)
          Accessor method provided to support Object2Dom marshalling.
 void setType(java.lang.String type)
          Accessor method provided to support Object2Dom marshalling.
 void setTypeOwner(java.lang.String typeOwner)
          Accessor method provided to support Object2Dom marshalling.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DIRECTION_IN

public static final java.lang.String DIRECTION_IN
Constants describing the IN/OUT class of the parameter.

See Also:
Constant Field Values

DIRECTION_OUT

public static final java.lang.String DIRECTION_OUT
See Also:
Constant Field Values

DIRECTION_IN_OUT

public static final java.lang.String DIRECTION_IN_OUT
See Also:
Constant Field Values
Constructor Detail

Parameter

public Parameter()
Default constructor provided to support Object2Dom marshalling. DO NOT USE UNDER ANY OTHER CIRCUMSTANCES.


Parameter

public Parameter(java.lang.String direction,
                 java.lang.String type)
Create a new parameter with the given direction and type. This constructor is for use only in the upgrading of old PL/SQL data models to new ones. The objects created with this constructor will not behave correctly if canTypeBeMapped is called on them.

Parameters:
direction - Direction of the parameter.
type - Type of the parameter.

Parameter

public Parameter(java.lang.String direction,
                 java.lang.String plsType,
                 java.lang.String dataType,
                 java.lang.String objType,
                 java.lang.String subType,
                 java.lang.String typeOwner,
                 java.sql.Connection dbConn,
                 java.lang.String dbConnName)
Create a new parameter with the given direction and type.

Parameters:
direction - The IN/OUT class of the parameter.
plsType - Name of the PL/SQL built-in type of the parameter, can be null.
dataType - Name of the database datatype corresponding to the PL/SQL built-in type of the parameter. This will be null if plsType is null.
objType - Name of the object type of the parameter, can be null.
subType - Name of the subtype of the parameter, if the parameter is an object type in a package. Can be null.
typeOwner - The owner of the parameter type.
dbConn - Connection to the database that holds the program unit this parameter is part of.
dbConnName - JDeveloper name of the connection - we need this if we are to be able to load parameters in from XML correctly.
Method Detail

setDirection

public void setDirection(java.lang.String direction)
Accessor method provided to support Object2Dom marshalling. DO NOT USE UNDER ANY OTHER CIRCUMSTANCES.


getDirection

public java.lang.String getDirection()
Returns:
The IN/OUT class of the parameter.

setDataType

public void setDataType(java.lang.String dataType)
Accessor method provided to support Object2Dom marshalling. DO NOT USE UNDER ANY OTHER CIRCUMSTANCES.


getDataType

public java.lang.String getDataType()
Accessor method provided to support Object2Dom marshalling. DO NOT USE UNDER ANY OTHER CIRCUMSTANCES.


setType

public void setType(java.lang.String type)
Accessor method provided to support Object2Dom marshalling. DO NOT USE UNDER ANY OTHER CIRCUMSTANCES.


getType

public java.lang.String getType()
Accessor method provided to support Object2Dom marshalling. DO NOT USE UNDER ANY OTHER CIRCUMSTANCES.


setDeclaredIn

public void setDeclaredIn(java.lang.String declaredIn)
Accessor method provided to support Object2Dom marshalling. DO NOT USE UNDER ANY OTHER CIRCUMSTANCES.


getDeclaredIn

public java.lang.String getDeclaredIn()
Accessor method provided to support Object2Dom marshalling. DO NOT USE UNDER ANY OTHER CIRCUMSTANCES.


setPlsqlType

public void setPlsqlType(boolean plsqlType)
Accessor method provided to support Object2Dom marshalling. DO NOT USE UNDER ANY OTHER CIRCUMSTANCES.


isPlsqlType

public boolean isPlsqlType()
Accessor method provided to support Object2Dom marshalling. DO NOT USE UNDER ANY OTHER CIRCUMSTANCES.


setTypeOwner

public void setTypeOwner(java.lang.String typeOwner)
Accessor method provided to support Object2Dom marshalling. DO NOT USE UNDER ANY OTHER CIRCUMSTANCES.


getTypeOwner

public java.lang.String getTypeOwner()
Accessor method provided to support Object2Dom marshalling. DO NOT USE UNDER ANY OTHER CIRCUMSTANCES.


setDBConnName

public void setDBConnName(java.lang.String dbConnName)
Accessor method provided to support Object2Dom marshalling. DO NOT USE UNDER ANY OTHER CIRCUMSTANCES.


getDBConnName

public java.lang.String getDBConnName()
Accessor method provided to support Object2Dom marshalling. DO NOT USE UNDER ANY OTHER CIRCUMSTANCES.


setSubParameters

public void setSubParameters(java.util.List subParameters)
Accessor method provided to support Object2Dom marshalling. DO NOT USE UNDER ANY OTHER CIRCUMSTANCES.


getSubParameters

public java.util.List getSubParameters()
Accessor method provided to support Object2Dom marshalling. DO NOT USE UNDER ANY OTHER CIRCUMSTANCES.


addSubParameter

public void addSubParameter(Parameter subParam)
Add a sub-parameter to this parameter. Sub-parameters will exist if a program unit uses PL/SQL records, ref cursors or PL/SQL tables.

Parameters:
subParam - Sub-parameter to add to this parameter.

getQualifiedType

public java.lang.String getQualifiedType()
Returns:
The type of the parameter, qualified with the scope it was declared in, if such a scope exists.

canTypeBeMapped

public boolean canTypeBeMapped(oracle.jdevimpl.webservices.util.PLSQLJavaTypeMap plsqlToJava,
                               oracle.jdevimpl.webservices.util.JavaXSDTypeMap javaToXSD,
                               java.util.Map typesValidated)
                        throws java.sql.SQLException
Determine whether the type of this parameter can be serialised in XML once JPublisher has mapped it to a Java type.

Parameters:
plsqlToJava - Map of PL/SQL types to Java types.
javaToXSD - Map of Java types to XSD types.
typesValidated - Map of PL/SQL user types that have previously been validated, to save us re-calculating results we already know.
Returns:
True if it can be mapped, false otherwise.
Throws:
java.sql.SQLException - if checking for an object type failed.

getXSDType

public java.lang.String getXSDType(oracle.jdevimpl.webservices.util.PLSQLJavaTypeMap plsqlToJava,
                                   oracle.jdevimpl.webservices.util.JavaXSDTypeMap javaToXSD)
Determine and return the equivalent XSD type for this parameter.

Parameters:
plsqlToJava - Map of PL/SQL types to Java types.
javaToXSD - Map of Java types to XSD types.
Returns:
XSD type of parameter, null if no mapping exists.

Extension SDK

 

Copyright © 1997, 2004, Oracle. All rights reserved.