public class ListProperty extends BaseProperty implements Cloneable
Modifier and Type | Class and Description |
---|---|
static class |
ListProperty.NotifyList
List implementation for updating dirty flag when updated.
|
Modifier and Type | Field and Description |
---|---|
protected List<String> |
list
We make this a notifying list, because we must propagate any value updates to the owner document.
|
documentReference, localEntityReferenceSerializer, ownerDocument, referenceCache
Constructor and Description |
---|
ListProperty() |
Modifier and Type | Method and Description |
---|---|
ListProperty |
clone() |
protected void |
cloneInternal(BaseProperty clone)
Subclasses override this to copy values during cloning.
|
boolean |
equals(Object obj) |
String |
getFormStringSeparator() |
List<String> |
getList() |
String |
getTextValue()
This method is called by Hibernate to get the raw value to store in the database.
|
Object |
getValue() |
protected void |
mergeValue(Object previousValue,
Object newValue,
MergeResult mergeResult)
Try to apply 3 ways merge on property value.
|
void |
setFormStringSeparator(String formStringSeparator) |
void |
setList(List<String> list)
Starting from 4.3M2, this method will copy the list passed as parameter.
|
void |
setValue(Object value) |
String |
toSingleFormString() |
String |
toString() |
String |
toText() |
org.dom4j.Element |
toXML() |
apply, createReference, getClassType, getCustomMappingValue, getId, getObject, hashCode, isValueDirty, merge, setClassType, setId, setObject, setOwnerDocument, setValueDirty, setValueDirty, toFormString, toXMLString
getDocumentReference, getLocalKey, getLocalUidStringEntityReferenceSerializer, getName, getOwnerDocument, getPrettyName, getReference, setDocumentReference, setName, setPrettyName
finalize, getClass, notify, notifyAll, wait, wait, wait
getDocumentReference, getName, getReference, setDocumentReference, setName
public String getFormStringSeparator()
public void setFormStringSeparator(String formStringSeparator)
public Object getValue()
getValue
in class BaseProperty
public void setValue(Object value)
setValue
in class BaseProperty
public String getTextValue()
public String toText()
toText
in class BaseProperty
public String toSingleFormString()
public boolean equals(Object obj)
equals
in class BaseProperty
public ListProperty clone()
clone
in interface PropertyInterface
clone
in class BaseProperty
protected void cloneInternal(BaseProperty clone)
BaseProperty
cloneInternal
in class BaseProperty
clone
- The cloned value.public void setList(List<String> list)
list
- The list to copy.public org.dom4j.Element toXML()
toXML
in interface PropertyInterface
toXML
in class BaseProperty
public String toString()
This is important.. Otherwise we can get a stackoverflow calling toXML()
toString
in interface ElementInterface
toString
in class BaseProperty
BaseProperty.toString()
protected void mergeValue(Object previousValue, Object newValue, MergeResult mergeResult)
BaseProperty
mergeValue
in class BaseProperty
previousValue
- the previous version of the valuenewValue
- the new version of the valuemergeResult
- merge reportCopyright © 2004–2014 XWiki. All rights reserved.