Class MetaData<T>
java.lang.Object
se.conciliate.extensions.documents.MetaData<T>
- Direct Known Subclasses:
MetaData.BooleanValue
,MetaData.DateTimeValue
,MetaData.HiddenValue
,MetaData.HtmlValue
,MetaData.ImageValue
,MetaData.MTSymbolValue
,MetaData.NumberValue
,MetaData.OptionsValue
,MetaData.TextValue
,MetaData.UrlValue
Meta-data value connected to a single document.
All meta-data are immutable. There are only a fixed number of meta data
implementations. These are:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final class
Represents a boolean value.static final class
Represents a date/time value.static final class
Represents a transient value that is never shown in the user-interface.static final class
Represents a html value.static final class
Represents an image value.static final class
Represents an MTSymbol.static final class
Represents a number value.static final class
Represents a value chosen from a set list of values.static final class
Represents simple, non-formatted text.static final class
Represents a URL value. -
Method Summary
Modifier and TypeMethodDescriptionboolean
Checks this meta data's equality relation to some other object.getData()
abstract MetaDataType<? extends MetaData<T>>
getType()
int
hashCode()
Returns the hash for this meta data.boolean
isNull()
Returns true if this is a null value.Returns a string representation of the data.
-
Method Details
-
getType
- Returns:
- the type of the data.
-
getData
- Returns:
- The non-null data.
-
isNull
public boolean isNull()Returns true if this is a null value.- Returns:
- true if this is a null value.
-
setData
- Parameters:
data
- A new value.- Returns:
- A copy of this meta-data with the given value as the meta-data's data.
-
stringPresentation
Returns a string representation of the data. This will be shown for example in document lists.- Returns:
- a string representation of the data.
-
hashCode
public int hashCode()Returns the hash for this meta data. The hash is based on the hash of the data's meta data type and the hash of the data itself. -
equals
Checks this meta data's equality relation to some other object. Will return false for any object that is not a meta data instance. Meta data is considered equal if their meta data type and data are equal.
-