|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface PartialDataObject
HAP-specific extension to DataObject
.
A DataObject
of which only a subset of its properties
are available. Getting or setting a property which is not available
results in an PropertyNotAvailableException
being thrown.
A PartialDataObject that only has its identity property available is called a
proxy.
PartialDataObjects are typically used (1) to allow dataobjects to have only a subset of their
many-valued properties available and (2) to enable data object proxies.
Properties that are not available are also not set (i.e. DataObject.isSet(int)
return false).
Snapshot
Field Summary | |
---|---|
static java.lang.Object |
UNAVAILABLE_PROPERTY
Marker value for unavailable properties |
Method Summary | |
---|---|
PartialDataObject |
createDataObject(int index)
Returns a new data object contained by this object using the specified property,
which must be a containment property . |
PartialDataObject |
createDataObject(int propertyIndex,
java.lang.String namespaceURI,
java.lang.String typeName)
Returns a new data object contained by this object using the specified property,
which must be a containment property . |
PartialDataObject |
createDataObject(Property property)
Returns a new data object contained by this object using the specified property,
which must be a containment property . |
PartialDataObject |
createDataObject(Property property,
Type type)
Returns a new data object contained by this object using the specified property,
which must be of containment type . |
PartialDataObject |
createDataObject(java.lang.String name)
Returns a new data object contained by this object using the specified property,
which must be a containment property . |
PartialDataObject |
createDataObject(java.lang.String propertyName,
java.lang.String namespaceURI,
java.lang.String typeName)
Returns a new data object contained by this object using the specified property,
which must be a containment property . |
PartialDataObject |
getContainer()
Returns the containing data object
or null if there is no container. |
Property |
getContainmentProperty()
Return the Property of the data object containing this data object
or null if there is no container. |
PartialDataObject |
getDataObject(int index)
Returns the value of a DataObject property identified by the specified property index. |
PartialDataObject |
getDataObject(Property property)
Returns the value of the specified DataObject property. |
PartialDataObject |
getDataObject(java.lang.String name)
Returns the value of a DataObject property identified by the specified path. |
java.lang.Object |
getIdentity()
|
Type |
getType()
Returns the data object's type. |
boolean |
isAvailable(Property property)
|
boolean |
isProxy()
|
void |
setIdentity(java.lang.Object object)
Sets the value of the identity property for this
instance. |
void |
setUnavailable(Property property)
Strips the property such that is no longer available. |
Field Detail |
---|
static final java.lang.Object UNAVAILABLE_PROPERTY
Method Detail |
---|
boolean isAvailable(Property property)
void setUnavailable(Property property)
boolean isProxy()
java.lang.Object getIdentity()
identity property
for this
instance.void setIdentity(java.lang.Object object)
identity property
for this
instance.
Type getType()
DataObject
The type defines the Properties available for reflective access.
getType
in interface DataObject
Property getContainmentProperty()
DataObject
data object
containing this data object
or null
if there is no container.
getContainmentProperty
in interface DataObject
PartialDataObject getContainer()
DataObject
data object
or null
if there is no container.
getContainer
in interface DataObject
null
.PartialDataObject getDataObject(java.lang.String name)
DataObject
DataObject
property identified by the specified path.
getDataObject
in interface DataObject
name
- the path to a valid object and property.
DataObject
value of the specified property.DataObject.get(String)
PartialDataObject getDataObject(Property property)
DataObject
DataObject
property.
getDataObject
in interface DataObject
property
- the property to get.
DataObject
value of the specified property.DataObject.get(Property)
PartialDataObject getDataObject(int index)
DataObject
DataObject
property identified by the specified property index.
getDataObject
in interface DataObject
index
- the index of the property.
DataObject
value of the specified property.DataObject.get(int)
PartialDataObject createDataObject(java.lang.String name)
DataObject
data object
contained by this object using the specified property,
which must be a containment property
.
The type of the created object is the declared type
of the specified property.
createDataObject
in interface DataObject
name
- the name of the specified containment property.
DataObject.createDataObject(String, String, String)
PartialDataObject createDataObject(int index)
DataObject
data object
contained by this object using the specified property,
which must be a containment property
.
The type of the created object is the declared type
of the specified property.
createDataObject
in interface DataObject
index
- the index of the specified containment property.
DataObject.createDataObject(int, String, String)
PartialDataObject createDataObject(Property property)
DataObject
data object
contained by this object using the specified property,
which must be a containment property
.
The type of the created object is the declared type
of the specified property.
createDataObject
in interface DataObject
property
- the specified containment property.
DataObject.createDataObject(Property, Type)
PartialDataObject createDataObject(java.lang.String propertyName, java.lang.String namespaceURI, java.lang.String typeName)
DataObject
data object
contained by this object using the specified property,
which must be a containment property
.
The type of the created object is specified by the packageURI and typeName arguments.
The specified type must be a compatible target for the property identified by propertyName.
createDataObject
in interface DataObject
propertyName
- the name of the specified containment property.namespaceURI
- the namespace URI of the package containing the type of object to be created.typeName
- the name of a type in the specified package.
DataObject.createDataObject(String)
,
DataGraph.getType(java.lang.String, java.lang.String)
PartialDataObject createDataObject(int propertyIndex, java.lang.String namespaceURI, java.lang.String typeName)
DataObject
data object
contained by this object using the specified property,
which must be a containment property
.
The type of the created object is specified by the packageURI and typeName arguments.
The specified type must be a compatible target for the property identified by propertyIndex.
createDataObject
in interface DataObject
propertyIndex
- the index of the specified containment property.namespaceURI
- the namespace URI of the package containing the type of object to be created.typeName
- the name of a type in the specified package.
DataObject.createDataObject(int)
,
DataGraph.getType(java.lang.String, java.lang.String)
PartialDataObject createDataObject(Property property, Type type)
DataObject
data object
contained by this object using the specified property,
which must be of containment type
.
The type of the created object is specified by the type argument,
which must be a compatible target for the speicifed property.
createDataObject
in interface DataObject
property
- a containment property of this object.type
- the type of object to be created.
DataObject.createDataObject(int)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |