org.xwiki.model.reference
Class ObjectReference
java.lang.Object
org.xwiki.model.reference.EntityReference
org.xwiki.model.reference.ObjectReference
- All Implemented Interfaces:
- Serializable, Cloneable, Comparable<EntityReference>
public class ObjectReference
- extends EntityReference
Reference to an object in a document (by classname and index, document, space, wiki).
- Since:
- 2.3M1
- Version:
- $Id$
- See Also:
- Serialized Form
|
Method Summary |
void |
setParent(EntityReference parent)
Overridden to ensure that the parent of an object is always a document. |
void |
setType(EntityType type)
Overridden to check the type to be an object type. |
| Methods inherited from class org.xwiki.model.reference.EntityReference |
clone, compareTo, equals, extractReference, getChild, getName, getParent, getRoot, getType, hashCode, setChild, setName, toString |
ObjectReference
public ObjectReference(EntityReference reference)
- Constructor which would raise exceptions if the source entity reference does not have the appropriate type or
parent, etc.
- Parameters:
reference - the raw reference to build this object reference from
ObjectReference
public ObjectReference(String wiki,
String space,
String document,
String objectName)
- Parameters:
wiki - wiki where the parent document of the object isspace - space where the parent document of the object isdocument - parent document of the objectobjectName - the name of the object
ObjectReference
public ObjectReference(String objectName,
DocumentReference documentReference)
- Parameters:
objectName - the name of the objectdocumentReference - the reference of the parent document of the object
setType
public void setType(EntityType type)
-
Overridden to check the type to be an object type.
- Overrides:
setType in class EntityReference
- See Also:
EntityReference.setType(org.xwiki.model.EntityType)
setParent
public void setParent(EntityReference parent)
-
Overridden to ensure that the parent of an object is always a document.
- Overrides:
setParent in class EntityReference
- See Also:
EntityReference.setParent(org.xwiki.model.reference.EntityReference)
Copyright © 2004-2011 XWiki. All Rights Reserved.