|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface IHasAttributes
| Method Summary | |
|---|---|
IAttribute |
addAttribute(IAttribute copyFrom)
Creates a new Attribute for this container of attributes (typically IEntity) by copying the data from
the passed IAttribute. |
IAttribute |
addAttribute(URI attrID)
Creates a new Attribute for this container of attributes (typically IEntity). |
IEntity |
addAttributeValue(URI attrType,
String entityId)
|
IAttribute |
getAttribute(URI attrID)
Returns the specified attribute of this object. |
Iterator |
getAttributes()
Return all attributes of this object |
ISingleValuedAttribute |
getSingleValuedAttribute(URI attrID)
Returns the specified attribute of this object as an ISingleValuedAttribute. |
void |
removeAttribute(URI attrID)
Deletes the attribute specified by attrID. |
void |
removeAttributeValue(IAttribute attr)
Deletes an attribute's value(s) based on the information passed in attr. |
void |
removeAttributeValue(URI attrID,
Object value)
Deletes the specified value from the specified attrID. |
| Method Detail |
|---|
Iterator getAttributes()
throws IdASException
IAttributes.
IdASException
IAttribute getAttribute(URI attrID)
throws IdASException
attrID - The identifier of the attribute to be returned.
IAttribute or null if none exits.
IdASException
ISingleValuedAttribute getSingleValuedAttribute(URI attrID)
throws IdASException,
NotSingleValuedAttributeException
attrID - The identifier of the attribute to be returned.
IAttribute or null if none exits.
IdASException
NotSingleValuedAttributeException - when the specified attrID is not
specified by its model as a single-valued attribute.
IAttribute addAttribute(URI attrID)
throws IdASException,
InvalidTypeException
IEntity).
This call is typically followed by one or more calls to
IAttribute.addValue(java.net.URI), IAttribute.addSimpleValue(java.net.URI, java.lang.Object),
IAttribute.addComplexValue(java.net.URI), (@link IHasMetadata#addMetadata} on
the returned IAttribute
Note: If the specified attribute already exists, the subsequently added
values are added to the entity, adding to the existing values of that attribute
(subject to any model restrictions).
Note: This operation is only applied to any backing data store after
IContext.applyUpdates() is called.
attrID - The URI specifying the identifier of the Attribute being created
{@link - IdASException}
{@link - InvalidTypeException} when the attribute type is invalid
IdASException
InvalidTypeException
IAttribute addAttribute(IAttribute copyFrom)
throws IdASException
IEntity) by copying the data from
the passed IAttribute.
Note: If the specified attribute already exists, the subsequently added
values are added to the entity, adding to the existing values of that attribute
(subject to any model restrictions).
Note: This operation is only applied to any backing data store after
IContext.applyUpdates() is called.
copyFrom - an IAttribute from which data is copied to construct a new
Attribute
{@link - IdASException}
IdASException
IEntity addAttributeValue(URI attrType,
String entityId)
throws IdASException
IdASException
void removeAttribute(URI attrID)
throws IdASException
getAttribute(URI) and then calling remove on the returned IAttribute.
More importantly however is that this method allows
an attribute to be removed when the caller has permissions
to remove, but no permissions to read that attribute.
Note: This operation is only applied to any backing data store after
IContext.applyUpdates() is called.
attrID - identifies the attribute to be removed
IdASException
void removeAttributeValue(URI attrID,
Object value)
throws IdASException
getAttribute(URI), then fetching the
appropriate value from the returned IAttribute,
and then calling remove on that value.
More importantly however is that this method allows
an attribute value to be removed when the caller has
permissions to remove values, but no permissions to
read that attribute or its values.
Note: This operation is only applied to any backing data store after
IContext.applyUpdates() is called.
attrID - identifies the simple attribute to be removedvalue - identifies the attribute value to be removed.
Note that this represents the data backing the simple attribute and is not an ISimpleAttribute itself.
IdASException
void removeAttributeValue(IAttribute attr)
throws IdASException
removeAttributeValue(URI, Object) once for each value in attr.
Note: This operation is only applied to any backing data store after
IContext.applyUpdates() is called.
attr - Holds one or more values to be deleted from the
attribute (named in attr)
IdASException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||