org.xwiki.model.reference
Class ClassPropertyReference

java.lang.Object
  extended by org.xwiki.model.reference.EntityReference
      extended by org.xwiki.model.reference.ClassPropertyReference
All Implemented Interfaces:
Serializable, Cloneable, Comparable<EntityReference>

public class ClassPropertyReference
extends EntityReference

References a property in a class in a document (the description of the property).

Since:
3.2M1
Version:
$Id$
See Also:
Serialized Form

Constructor Summary
ClassPropertyReference(EntityReference reference)
          Constructor which would raise exceptions if the source entity reference does not have the appropriate type or parent, etc.
ClassPropertyReference(String propertyName, DocumentReference classReference)
          Builds a property reference for the passed property in the passed object.
ClassPropertyReference(String wiki, String space, String page, String propertyName)
           
 
Method Summary
 void setParent(EntityReference parent)
          
 void setType(EntityType type)
          
 
Methods inherited from class org.xwiki.model.reference.EntityReference
clone, compareTo, equals, extractReference, getChild, getName, getParent, getRoot, getType, hashCode, setChild, setName, toString
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ClassPropertyReference

public ClassPropertyReference(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

ClassPropertyReference

public ClassPropertyReference(String propertyName,
                              DocumentReference classReference)
Builds a property reference for the passed property in the passed object.

Parameters:
propertyName - the name of the property to create reference for
classReference - the reference to the class whose property is

ClassPropertyReference

public ClassPropertyReference(String wiki,
                              String space,
                              String page,
                              String propertyName)
Parameters:
wiki - the wiki of the document where the parent class of this property is
space - the space of the document where the parent class of this property is
page - the document where the parent class of this property is
objectName - the name of the parent class of this property
propertyName - the name of the property to refer to
Method Detail

setType

public void setType(EntityType type)

Overridden to check the type to be a property 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 a property is always an object.

Overrides:
setParent in class EntityReference
See Also:
EntityReference.setParent(org.xwiki.model.reference.EntityReference)


Copyright © 2004-2011 XWiki. All Rights Reserved.