T
- the class of the property's valuepublic class SimpleProperty<T> extends VCardProperty
Modifier and Type | Field and Description |
---|---|
protected T |
value |
group, parameters
Constructor and Description |
---|
SimpleProperty(SimpleProperty<T> original)
Copy constructor.
|
SimpleProperty(T value)
Creates a valued property
|
Modifier and Type | Method and Description |
---|---|
protected void |
_validate(List<ValidationWarning> warnings,
VCardVersion version,
VCard vcard)
Checks the property for data consistency problems or deviations from the
spec.
|
boolean |
equals(Object obj) |
T |
getValue()
Gets the value of this property.
|
int |
hashCode() |
void |
setValue(T value)
Sets the value of this property.
|
protected Map<String,Object> |
toStringValues()
Gets string representations of the class's fields for the
VCardProperty.toString() method. |
addParameter, compareTo, copy, getGroup, getParameter, getParameters, getParameters, getSupportedVersions, isSupportedBy, removeParameter, setGroup, setParameter, setParameters, toString, validate
public SimpleProperty(T value)
value
- the valuepublic SimpleProperty(SimpleProperty<T> original)
original
- the property to make a copy ofpublic void setValue(T value)
value
- the valueprotected void _validate(List<ValidationWarning> warnings, VCardVersion version, VCard vcard)
VCardProperty
_validate
in class VCardProperty
warnings
- the list to add the warnings toversion
- the version to check the property againstvcard
- the vCard this property belongs toprotected Map<String,Object> toStringValues()
VCardProperty
Gets string representations of the class's fields for the
VCardProperty.toString()
method.
Meant to be overridden by child classes. The default implementation returns an empty map.
toStringValues
in class VCardProperty
public int hashCode()
hashCode
in class VCardProperty
public boolean equals(Object obj)
equals
in class VCardProperty
Copyright © 2012–2023 Michael Angstadt. All rights reserved.