|
Oracle Fusion Middleware Java API Reference for Oracle ADF Model 11g Release 1 (11.1.1) E10653-04 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectoracle.adf.model.adapter.AbstractImpl
public abstract class AbstractImpl
An abstract base class for all metadata driven data control implementations.
Data Controls implementations, child classes of this abstract class, must also implement any of the Data Control interfaces defined by the JSR 227 specification. The data control interfaces are available under "oracle.binding" package.
Field Summary | |
---|---|
static java.lang.String |
METHOD_CREATE
Name of the method to create the adapter instance. |
static java.lang.String |
METHOD_EXECUTE
Name of the method to execute the adapter instance. |
protected java.lang.String |
mName
Name of the data control. |
static java.lang.String |
SORT_CRITERIA
Key name for the sort criteria set for the data control. |
Constructor Summary | |
---|---|
AbstractImpl()
|
Method Summary | |
---|---|
void |
addParameter(java.lang.String name,
java.lang.String val)
Adds a parameter to the data control. |
protected java.lang.Object |
createAndAddNewRow(RowContext ctx)
Helper method to create a row and add the new row to the master row. |
java.lang.Object |
createEmptyDataSet(StructureDefinition struc,
boolean isCollection)
Creates an empty data set for a given structure. |
AdapterContext |
getAdapterContext()
Returns the current adapter context. |
AbstractDefinition |
getDefinition()
Gets the data control definition. |
java.lang.String[] |
getParameterNames()
Returns the name of the parameters set to this data control instance. |
java.lang.String |
getParameterValue(java.lang.String name)
Gets the value of an existing definition parameter. |
AdapterSortCriteria[] |
getSortCriteria(OperationBinding action)
Extracts and returns the sort criteria, if any, defined for the method action. |
StructureDefinition |
getStructureDef()
Gets the structure defintion for the data for this data control. |
StructureDefinition |
getStructureDef(java.lang.String typeName)
Gets the structure definition of a complex type. |
void |
processResult(java.lang.Object result,
java.util.Map bindingContext,
OperationBinding action)
Processes result created by the adapter's invokeOperation call. |
void |
setDefinition(AbstractDefinition def)
Sets the definition of this data control. |
void |
setName(java.lang.String name)
Sets the name of the data control implementation. |
void |
setParameterValue(java.lang.String name,
java.lang.String val)
Sets the value of an existing definition parameter. |
void |
setStructureDef(StructureDefImpl def)
Sets the structure definition of the data for this data control. |
boolean |
shouldReexecuteOperation(OperationInfo operationInfo)
Determines if a method should be reexecuted. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String METHOD_CREATE
OperationBinding
passed to the invokeAction
call.
public static final java.lang.String METHOD_EXECUTE
OperationBinding
passed to the invokeAction
call.
public static final java.lang.String SORT_CRITERIA
invokeOperation
method via
the MethodOperationBinding
object.
Implementation may use getSortCriteria
helper method to
get the sort criteria.
protected java.lang.String mName
Constructor Detail |
---|
public AbstractImpl()
Method Detail |
---|
public boolean shouldReexecuteOperation(OperationInfo operationInfo)
If the parameter value of a method changes, the framework executes the method. If the parameter values are not changed or the method has no parameters, the framework asks if the method should be reexecuted or the values that are already fetched before can be used.
public final void setName(java.lang.String name)
public final AdapterSortCriteria[] getSortCriteria(OperationBinding action)
action
- the operation for which the sort criteria can be defined.
public final java.lang.String[] getParameterNames()
public final java.lang.String getParameterValue(java.lang.String name)
name
- Name of the parameter.
public final void setParameterValue(java.lang.String name, java.lang.String val)
name
- Name of the parameter.val
- Value of the parameter.public final void addParameter(java.lang.String name, java.lang.String val)
name
- name of the parameter.val
- value of the parameter.public final void setStructureDef(StructureDefImpl def)
public final StructureDefinition getStructureDef()
public final StructureDefinition getStructureDef(java.lang.String typeName)
typeName
- name of the complex type.
public final java.lang.Object createEmptyDataSet(StructureDefinition struc, boolean isCollection)
struc
- the structure for which the empty row will be created.isCollection
- true if the return data set is a collection.
Map
representing the row structure. In case of a
collection data, it returns a Collection
. The returned
object will preserve the structure hierarchy as defined by the
given structure definition.protected final java.lang.Object createAndAddNewRow(RowContext ctx)
ctx
- current row context.
public final void setDefinition(AbstractDefinition def)
public final AbstractDefinition getDefinition()
public final void processResult(java.lang.Object result, java.util.Map bindingContext, OperationBinding action)
ADFm expects the result of a method call should be set to the binding context in a way that the framework can retrieve it according to the bind path created in the page definiion. This method takes the result and sets it properly in thge binding context properly.
Adapters should call this method from their invokeOperation
call after fetching the data from the data source.
result
- returned result of the method call.bindingContext
- the binding context.action
- action that is called on the data control.public final AdapterContext getAdapterContext()
|
Oracle Fusion Middleware Java API Reference for Oracle ADF Model 11g Release 1 (11.1.1) E10653-04 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |