|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.ojb.broker.metadata.ProcedureDescriptor
public abstract class ProcedureDescriptor
A ProcedureDescriptor contains information that is common for all types
of procedures/functions that are used to handle the persistence operations.
Note: Be careful when use ProcedureDescriptor variables or caching
ProcedureDescriptor instances, because instances could become invalid
during runtime (see MetadataManager).
| Constructor Summary | |
|---|---|
ProcedureDescriptor(ClassDescriptor classDescriptor,
String name)
Constructor declaration |
|
| Method Summary | |
|---|---|
protected void |
addArgument(ArgumentDescriptor argument)
Add an argument |
protected void |
addArguments(FieldDescriptor[] field)
Set up arguments for each FieldDescriptor in an array. |
void |
addAttribute(String attributeName,
String attributeValue)
Store the specified attribute and it's value. |
int |
getArgumentCount()
Retrieves the number of arguments that are passed to the procedure that this descriptor represents. |
Collection |
getArguments()
Get the argument descriptors for this procedure. |
String |
getAttribute(String attributeName)
Get the value of an attribute |
String |
getAttribute(String attributeName,
String defaultValue)
Get the value of an attribute |
String[] |
getAttributeNames()
Returns an array of the names of all atributes of this descriptor. |
Map |
getAttributes()
Returns the attribute map (name, value) of this descriptor. |
ClassDescriptor |
getClassDescriptor()
Retrieve the class descriptor that this object is related to. |
String |
getName()
Retrieve the the name of the procedure/function to invoke. |
FieldDescriptor |
getReturnValueFieldRef()
Retrieve the field descriptor that will receive the return value from the procedure/function... |
String |
getReturnValueFieldRefName()
Retrieve the name of the field descriptor that will receive the return value from the procedure/function... |
boolean |
hasReturnValue()
Is there a return value for this procedure? |
boolean |
hasReturnValues()
Does this procedure return any values to the 'caller'? |
void |
setReturnValueFieldRef(FieldDescriptor fieldDescriptor)
Change the the field descriptor that will receive the return value from the procedure/function... |
void |
setReturnValueFieldRef(String fieldName)
Change the field descriptor that will receive the return value from the procedure/function.. |
String |
toString()
|
abstract String |
toXML()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public ProcedureDescriptor(ClassDescriptor classDescriptor,
String name)
| Method Detail |
|---|
public final String getName()
public final void setReturnValueFieldRef(String fieldName)
fieldName - the name of the field that will receive the
return value from the procedure/function.public final void setReturnValueFieldRef(FieldDescriptor fieldDescriptor)
fieldDescriptor - the field descriptor that will receive the
return value from the procedure/function.public final FieldDescriptor getReturnValueFieldRef()
public final boolean hasReturnValue()
true if there is a return value for this
procedure.public final boolean hasReturnValues()
true if the procedure returns at least 1
value that is returned to the caller.public final String getReturnValueFieldRefName()
public final ClassDescriptor getClassDescriptor()
public abstract String toXML()
protected void addArgument(ArgumentDescriptor argument)
protected void addArguments(FieldDescriptor[] field)
public final Collection getArguments()
public final int getArgumentCount()
Note: The value returned by this method does not reflect the presence of any return value for the procedure
public void addAttribute(String attributeName,
String attributeValue)
AttributeContainer
addAttribute in interface AttributeContainerattributeName - the name of the attribute to retrieveattributeValue - the attribute's valueAttributeContainer.addAttribute(String, String)
public String getAttribute(String attributeName,
String defaultValue)
AttributeContainer
getAttribute in interface AttributeContainerattributeName - the attribute to retrievedefaultValue - the value to return if the attribute is not present
AttributeContainer.getAttribute(String, String)public String getAttribute(String attributeName)
AttributeContainer
getAttribute in interface AttributeContainerattributeName - the attribute to retrieve
AttributeContainer.getAttribute(String)public Map getAttributes()
public String[] getAttributeNames()
null)public String toString()
toString in class Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||