|
Oracle Fusion Middleware Java API Reference for Oracle ADF Model 11g Release 1 (11.1.1.1.0) E10653-02 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectoracle.jbo.server.RowImpl
oracle.jbo.server.EntityImpl
oracle.jbo.server.ejb.facade.EntityFacadeImpl
public abstract class EntityFacadeImpl
Abstract base class for Entity Facade.
This class extends
.
Beyond the base EntityImpl
EntityImpl
functionality, this class
is responsible for interacting with the Local Entity Bean instance.
When the user builds an Entity Facade for an Entity Bean, a subclass of this class is generated.
Field Summary | |
---|---|
protected javax.ejb.EJBLocalObject |
mEJBLocalObject
|
Fields inherited from class oracle.jbo.server.EntityImpl |
---|
CURRENT_VERSION, DML_DELETE, DML_INSERT, DML_UPDATE, MAXATTRCONST, ORACLE_ROWID_COLUMN, ORIGINAL_VERSION, SYS_EFFDT_ROW_SPLIT, XML_CI_CHANGED, XML_PK_CHANGED, XML_PK_CHANGED_YES |
Fields inherited from interface oracle.jbo.server.Entity |
---|
STATUS_DEAD, STATUS_DELETED, STATUS_MODIFIED, STATUS_UNMODIFIED |
Fields inherited from interface oracle.jbo.XMLInterface |
---|
XML_IGNORE_DEPTH_COUNT, XML_OPT_ALL_ROWS, XML_OPT_ASSOC_CONSISTENT, XML_OPT_CHANGES_ONLY, XML_OPT_LIMIT_RANGE |
Fields inherited from interface oracle.jbo.JboReservedVarNames |
---|
RESERVED_VAR_AGG_AVG, RESERVED_VAR_AGG_COUNT, RESERVED_VAR_AGG_MAX, RESERVED_VAR_AGG_MIN, RESERVED_VAR_AGG_SUM, RESERVED_VAR_AGGVAL_PREFIX, RESERVED_VAR_STRUCTURE_DEF |
Fields inherited from interface oracle.jbo.expr.JIReservedVarNames |
---|
RESERVED_VAR_VALUE |
Constructor Summary | |
---|---|
EntityFacadeImpl()
Constructs an Entity Facade. |
Method Summary | |
---|---|
protected void |
doDML(int operation,
TransactionEvent e)
Overrides the base implementation of doDML(int, oracle.jbo.server.TransactionEvent) . |
protected void |
doSelect(boolean lock)
Overrides the base implementation of doSelect(boolean) . |
java.lang.Object |
getAttributeInternal(int index)
Overrides the base implementation of getAttributeInternal(int)
to make it public . |
protected javax.ejb.EJBLocalObject |
getEJBLocalObject()
Returns the Local Entity Bean reference. |
boolean |
isAttributeUpdateable(int index)
Checks if the attribute is updateable. |
protected abstract void |
mergeBeanAttributes()
|
protected abstract void |
populateFromBean()
An abstract method responsible for populating Entity Facade attributes with the corresponding attribute values from the Entity Bean. |
void |
setAttribute(int index,
java.lang.Object val)
Sets the value of an attribute, given its index position. |
protected void |
setEJBLocalObject(javax.ejb.EJBLocalObject ejbObject)
Sets the Local Entity Bean reference. |
abstract void |
updateBean(javax.ejb.EJBLocalObject ejbObject)
An abstract method responsible for updating the Entity Bean with attribute values from this Entity Facade. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface oracle.jbo.Row |
---|
getAttributeSecurityHints, getAttributeSecurityHints, getEffectiveDateMode, getSecurityHints |
Methods inherited from interface oracle.jbo.XMLInterface |
---|
readXML, writeXML, writeXML, writeXML, writeXML |
Field Detail |
---|
protected javax.ejb.EJBLocalObject mEJBLocalObject
Constructor Detail |
---|
public EntityFacadeImpl()
Method Detail |
---|
protected abstract void mergeBeanAttributes() throws java.lang.Exception
java.lang.Exception
protected javax.ejb.EJBLocalObject getEJBLocalObject()
protected void setEJBLocalObject(javax.ejb.EJBLocalObject ejbObject)
ejbObject
- the Local Entity Bean.public boolean isAttributeUpdateable(int index)
EntityImpl
READ_ONLY
, UPDATEABLE_WHILE_NEW
, or
UPDATEABLE
.
This method can be overridden. For example, override this method if you want to check the updateable status and you have dependencies between two or more attributes.
isAttributeUpdateable
in interface Row
isAttributeUpdateable
in class EntityImpl
index
- the attribute's index (0-based).
false
if the attribute is READ_ONLY
;
true
if attribute is UPDATEABLE
or if the
attribute is UPDATEABLE_WHILE_NEW
and the current row is new.public void setAttribute(int index, java.lang.Object val)
EntityImpl
If there is a set method for this attribute in a subclass of this Entity Object, that method is invoked. The set method name is derived from the attribute name: for example, the method getDeptNo() pertains to an attribute named "Deptno".
This method should not be overridden; override
setAttributeInternal
instead.
setAttribute
in interface AttributeList
setAttribute
in class EntityImpl
index
- the index of the attribute.val
- the value to be assigned to the attribute. The class of the returned
value a Java type determined by this Entity Object's definition
object.protected void doSelect(boolean lock)
doSelect(boolean)
.
It populates Entity Facade attributes with the corresponding
attribute values from the Entity Bean by calling the abstract
method populateFromBean()
.
doSelect
in class EntityImpl
lock
- a flag indicating whether the Entity Facade
is being 'selected' for update (with a lock)
or not. This flag is currently unsed by
EntityFacadeImpl
.protected abstract void populateFromBean() throws java.lang.Exception
A subclass of this class has an implementation of this method which performs this operation specific to that subclass.
java.lang.Exception
- if something goes wrong while retrieving
attribute values from the Entity Bean or
while setting attibute values into this
Entity Facade. Note that it may throw an
EJB exception.public abstract void updateBean(javax.ejb.EJBLocalObject ejbObject) throws java.lang.Exception
A subclass of this class has an implementation of this method which performs this operation specific to that subclass.
ejbObject
- the Local Entity Bean.
java.lang.Exception
- if something goes wrong while retrieving
attribute values from this Entity Facade or
while setting attibute values into the
Entity Bean. Note that it may throw an
EJB exception.protected void doDML(int operation, TransactionEvent e)
doDML(int, oracle.jbo.server.TransactionEvent)
.
It performs data update operation, syncing the Entity Facade with the corresponding Local Entity Bean instance. If this Entity Facade is a new one, it will create a new Local Entity Bean instance. If this Facade was removed (deleted), it will remove the Entity Bean instance. If this Facade was updated, it will update the Entity Bean with the new attribute values.
doDML
in class EntityImpl
operation
- identifies the data update operation to perform.e
- describes the transaction event.public java.lang.Object getAttributeInternal(int index)
getAttributeInternal(int)
to make it public
.
getAttributeInternal
in class EntityImpl
index
- the attribute index.
|
Oracle Fusion Middleware Java API Reference for Oracle ADF Model 11g Release 1 (11.1.1.1.0) E10653-02 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |