Interface CompositeMetadata
-
- All Known Subinterfaces:
CommentableCompositeMetadata
,ModifiableCompositeMetadata
- All Known Implementing Classes:
JCRCompositeMetadata
@Deprecated public interface CompositeMetadata
Deprecated.UseRepositoryData
insteadMetadata container for anAmetysObject
.
Note that this can be recursive so that a CompositeMetadata can handle other CompositeMetadata.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static class
CompositeMetadata.MetadataType
Deprecated.Enumeration for metadata types.
-
Method Summary
All Methods Instance Methods Abstract Methods Deprecated Methods Modifier and Type Method Description void
copyTo(ModifiableCompositeMetadata metadata)
Deprecated.Copy the currentCompositeMetadata
to the given composite metadata.BinaryMetadata
getBinaryMetadata(String metadataName)
Deprecated.Returns the named metadata's value asBinaryMetadata
.
If the metadata does not exist, anUnknownMetadataException
is thrown.boolean
getBoolean(String metadataName)
Deprecated.Returns the named metadata's value as boolean.
If the metadata is multi-valued, one of the value is returned.
If the metadata does not exist, anUnknownMetadataException
is thrown.boolean
getBoolean(String metadataName, boolean defaultValue)
Deprecated.Returns the named metadata's value as boolean.
If the metadata is multi-valued, one of the value is returned.
If the metadata does not exist, the default value is returned.boolean[]
getBooleanArray(String metadataName)
Deprecated.Returns the named metadata's value as boolean array.boolean[]
getBooleanArray(String metadataName, boolean[] defaultValues)
Deprecated.Returns the named metadata's value as boolean array.
If the metadata does not exist, the default values are returned.CompositeMetadata
getCompositeMetadata(String metadataName)
Deprecated.Returns the named metadata's value asCompositeMetadata
.
If the metadata is multi-valued, one of the value is returned.
If the metadata does not exist anUnknownMetadataException
is thrown.Date
getDate(String metadataName)
Deprecated.Returns the named metadata's value as Date.
If the metadata is multi-valued, one of the value is returned.
If the metadata does not exist, anUnknownMetadataException
is thrown.Date
getDate(String metadataName, Date defaultValue)
Deprecated.Returns the named metadata's value as Date.
If the metadata is multi-valued, one of the value is returned.
If the metadata does not exist, the default value is returned.Date[]
getDateArray(String metadataName)
Deprecated.Returns the named metadata's value as Date array.Date[]
getDateArray(String metadataName, Date[] defaultValues)
Deprecated.Returns the named metadata's value as Date array.
If the metadata does not exist, the default values are returned.double
getDouble(String metadataName)
Deprecated.Returns the named metadata's value as double.
If the metadata is multi-valued, one of the value is returned.
If the metadata does not exist, anUnknownMetadataException
is thrown.double
getDouble(String metadataName, double defaultValue)
Deprecated.Returns the named metadata's value as double.
If the metadata is multi-valued, one of the value is returned.
If the metadata does not exist, the default value is returned.double[]
getDoubleArray(String metadataName)
Deprecated.Returns the named metadata's value as double array.double[]
getDoubleArray(String metadataName, double[] defaultValues)
Deprecated.Returns the named metadata's value as double array.
If the metadata does not exist, the default values are returned.String
getLocalizedString(String metadataName, Locale locale)
Deprecated.Returns the named metadata's value of a multilingual metadata as String.String
getLocalizedString(String metadataName, Locale locale, String defaultValue)
Deprecated.Returns the named metadata's value of a multilingual metadata as String.
If the metadata does not exist, the default value is returned.long
getLong(String metadataName)
Deprecated.Returns the named metadata's value as long.
If the metadata is multi-valued, one of the value is returned.
If the metadata does not exist, anUnknownMetadataException
is thrown.long
getLong(String metadataName, long defaultValue)
Deprecated.Returns the named metadata's value as long.
If the metadata is multi-valued, one of the value is returned.
If the metadata does not exist, the default value is returned.long[]
getLongArray(String metadataName)
Deprecated.Returns the named metadata's value as long array.long[]
getLongArray(String metadataName, long[] defaultValues)
Deprecated.Returns the named metadata's value as long array.
If the metadata does not exist, the default values are returned.String[]
getMetadataNames()
Deprecated.Returns an array containing metadata names.MultilingualString
getMultilingualString(String metadataName)
Deprecated.Returns the named metadata's values of a multilingual metadata.TraversableAmetysObject
getObjectCollection(String metadataName)
Deprecated.Returns an object collection metadata as aTraversableAmetysObject
.RichText
getRichText(String metadataName)
Deprecated.Returns the named metadata's value asRichText
.
If the metadata does not exist, anUnknownMetadataException
is thrown.String
getString(String metadataName)
Deprecated.Returns the named metadata's value as String.
If the metadata is multi-valued, one of the value is returned.
If the metadata does not exist, anUnknownMetadataException
is thrown.String
getString(String metadataName, String defaultValue)
Deprecated.Returns the named metadata's value as String.
If the metadata is multi-valued, one of the value is returned.
If the metadata does not exist, the default value is returned.String[]
getStringArray(String metadataName)
Deprecated.Returns the named metadata's value as String array.String[]
getStringArray(String metadataName, String[] defaultValues)
Deprecated.Returns the named metadata's value as String array.
If the metadata does not exist, the default values are returned.CompositeMetadata.MetadataType
getType(String metadataName)
Deprecated.Returns the type of the given metadata.UserIdentity
getUser(String metadataName)
Deprecated.Returns the named metadata's value asUserIdentity
.
If the metadata does not exist, anUnknownMetadataException
is thrown.UserIdentity
getUser(String metadataName, UserIdentity defaultValue)
Deprecated.Returns the named metadata's value asUserIdentity
.
If the metadata does not exist, the default value is returned.UserIdentity[]
getUserArray(String metadataName)
Deprecated.Returns the named metadata's value asUserIdentity
array.UserIdentity[]
getUserArray(String metadataName, UserIdentity[] defaultValues)
Deprecated.Returns the named metadata's value asUserIdentity
array.
If the metadata does not exist, the default values are returned.boolean
hasMetadata(String metadataName)
Deprecated.Tests if a metadata with a given name exists.boolean
isMultiple(String metadataName)
Deprecated.Test if the given metadata is multiple.
-
-
-
Method Detail
-
hasMetadata
boolean hasMetadata(String metadataName)
Deprecated.Tests if a metadata with a given name exists.- Parameters:
metadataName
- the metadataName to test.- Returns:
true
if the given metadata exists,false
otherwise.- Throws:
AmetysRepositoryException
- if an error occurs.
-
getType
CompositeMetadata.MetadataType getType(String metadataName) throws UnknownMetadataException, AmetysRepositoryException
Deprecated.Returns the type of the given metadata.- Parameters:
metadataName
- metadata name.- Returns:
- the type of the given metadata.
- Throws:
UnknownMetadataException
- if the named metadata does not exist.AmetysRepositoryException
- if an error occurs.
-
getBinaryMetadata
BinaryMetadata getBinaryMetadata(String metadataName) throws UnknownMetadataException, AmetysRepositoryException
Deprecated.Returns the named metadata's value asBinaryMetadata
.
If the metadata does not exist, anUnknownMetadataException
is thrown.- Parameters:
metadataName
- the metadata name.- Returns:
- the metadata value as BinaryMetadata.
- Throws:
UnknownMetadataException
- if the named metadata does not exist.AmetysRepositoryException
- if an error occurs.
-
getRichText
RichText getRichText(String metadataName) throws UnknownMetadataException, AmetysRepositoryException
Deprecated.Returns the named metadata's value asRichText
.
If the metadata does not exist, anUnknownMetadataException
is thrown.- Parameters:
metadataName
- the metadata name.- Returns:
- the metadata value as RichText.
- Throws:
UnknownMetadataException
- if the named metadata does not exist.AmetysRepositoryException
- if an error occurs.
-
getString
String getString(String metadataName) throws UnknownMetadataException, AmetysRepositoryException
Deprecated.Returns the named metadata's value as String.
If the metadata is multi-valued, one of the value is returned.
If the metadata does not exist, anUnknownMetadataException
is thrown.- Parameters:
metadataName
- the metadata name.- Returns:
- the metadata value as String.
- Throws:
UnknownMetadataException
- if the named metadata does not exist.AmetysRepositoryException
- if an error occurs.
-
getString
String getString(String metadataName, String defaultValue) throws AmetysRepositoryException
Deprecated.Returns the named metadata's value as String.
If the metadata is multi-valued, one of the value is returned.
If the metadata does not exist, the default value is returned.- Parameters:
metadataName
- the metadata name.defaultValue
- the default value.- Returns:
- the metadata value as String or the default value if metadata is not set.
- Throws:
AmetysRepositoryException
- if an error occurs.
-
getLocalizedString
String getLocalizedString(String metadataName, Locale locale) throws UnknownMetadataException, AmetysRepositoryException
Deprecated.Returns the named metadata's value of a multilingual metadata as String.- Parameters:
metadataName
- the metadata name.locale
- the locale of value to retrieve- Returns:
- the metadata value as String
- Throws:
UnknownMetadataException
- if the named metadata does not exist for the given locale.AmetysRepositoryException
- if an error occurs.
-
getLocalizedString
String getLocalizedString(String metadataName, Locale locale, String defaultValue) throws AmetysRepositoryException
Deprecated.Returns the named metadata's value of a multilingual metadata as String.
If the metadata does not exist, the default value is returned.- Parameters:
metadataName
- the metadata name.locale
- the locale of value to retrievedefaultValue
- the default value.- Returns:
- the metadata value as String or the default value if metadata is not set.
- Throws:
AmetysRepositoryException
- if an error occurs.
-
getMultilingualString
MultilingualString getMultilingualString(String metadataName) throws AmetysRepositoryException
Deprecated.Returns the named metadata's values of a multilingual metadata.- Parameters:
metadataName
- the metadata name.- Returns:
- the metadata values for all existing locales
- Throws:
AmetysRepositoryException
- if an error occurs.
-
getStringArray
String[] getStringArray(String metadataName) throws UnknownMetadataException, AmetysRepositoryException
Deprecated.Returns the named metadata's value as String array.- Parameters:
metadataName
- metadata name.- Returns:
- metadata value as String array.
- Throws:
UnknownMetadataException
- if the named metadata does not exist.AmetysRepositoryException
- if an error occurs.
-
getStringArray
String[] getStringArray(String metadataName, String[] defaultValues) throws AmetysRepositoryException
Deprecated.Returns the named metadata's value as String array.
If the metadata does not exist, the default values are returned.- Parameters:
metadataName
- metadata name.defaultValues
- the default values.- Returns:
- metadata value as String array or the default values if metadata is not set.
- Throws:
AmetysRepositoryException
- if an error occurs.
-
getDate
Date getDate(String metadataName) throws UnknownMetadataException, AmetysRepositoryException
Deprecated.Returns the named metadata's value as Date.
If the metadata is multi-valued, one of the value is returned.
If the metadata does not exist, anUnknownMetadataException
is thrown.- Parameters:
metadataName
- the metadata name.- Returns:
- the metadata value as Date.
- Throws:
UnknownMetadataException
- if the named metadata does not exist.AmetysRepositoryException
- if an error occurs.
-
getDate
Date getDate(String metadataName, Date defaultValue) throws AmetysRepositoryException
Deprecated.Returns the named metadata's value as Date.
If the metadata is multi-valued, one of the value is returned.
If the metadata does not exist, the default value is returned.- Parameters:
metadataName
- the metadata name.defaultValue
- the default value.- Returns:
- the metadata value as Date or the default value if metadata is not set.
- Throws:
AmetysRepositoryException
- if an error occurs.
-
getDateArray
Date[] getDateArray(String metadataName) throws UnknownMetadataException, AmetysRepositoryException
Deprecated.Returns the named metadata's value as Date array.- Parameters:
metadataName
- metadata name.- Returns:
- metadata value as Date array.
- Throws:
UnknownMetadataException
- if the named metadata does not exist.AmetysRepositoryException
- if an error occurs.
-
getDateArray
Date[] getDateArray(String metadataName, Date[] defaultValues) throws AmetysRepositoryException
Deprecated.Returns the named metadata's value as Date array.
If the metadata does not exist, the default values are returned.- Parameters:
metadataName
- metadata name.defaultValues
- the default values.- Returns:
- metadata value as Date array or the default values if metadata is not set.
- Throws:
AmetysRepositoryException
- if an error occurs.
-
getLong
long getLong(String metadataName) throws UnknownMetadataException, AmetysRepositoryException
Deprecated.Returns the named metadata's value as long.
If the metadata is multi-valued, one of the value is returned.
If the metadata does not exist, anUnknownMetadataException
is thrown.- Parameters:
metadataName
- the metadata name.- Returns:
- the metadata value as long.
- Throws:
UnknownMetadataException
- if the named metadata does not exist.AmetysRepositoryException
- if an error occurs.
-
getLong
long getLong(String metadataName, long defaultValue) throws AmetysRepositoryException
Deprecated.Returns the named metadata's value as long.
If the metadata is multi-valued, one of the value is returned.
If the metadata does not exist, the default value is returned.- Parameters:
metadataName
- the metadata name.defaultValue
- the default value.- Returns:
- the metadata value as long or the default value if metadata is not set.
- Throws:
AmetysRepositoryException
- if an error occurs.
-
getLongArray
long[] getLongArray(String metadataName) throws UnknownMetadataException, AmetysRepositoryException
Deprecated.Returns the named metadata's value as long array.- Parameters:
metadataName
- metadata name.- Returns:
- metadata value as long array.
- Throws:
UnknownMetadataException
- if the named metadata does not exist.AmetysRepositoryException
- if an error occurs.
-
getLongArray
long[] getLongArray(String metadataName, long[] defaultValues) throws AmetysRepositoryException
Deprecated.Returns the named metadata's value as long array.
If the metadata does not exist, the default values are returned.- Parameters:
metadataName
- metadata name.defaultValues
- the default values.- Returns:
- metadata value as long array or the default values if metadata is not set.
- Throws:
AmetysRepositoryException
- if an error occurs.
-
getDouble
double getDouble(String metadataName) throws UnknownMetadataException, AmetysRepositoryException
Deprecated.Returns the named metadata's value as double.
If the metadata is multi-valued, one of the value is returned.
If the metadata does not exist, anUnknownMetadataException
is thrown.- Parameters:
metadataName
- the metadata name.- Returns:
- the metadata value as double.
- Throws:
UnknownMetadataException
- if the named metadata does not exist.AmetysRepositoryException
- if an error occurs.
-
getDouble
double getDouble(String metadataName, double defaultValue) throws AmetysRepositoryException
Deprecated.Returns the named metadata's value as double.
If the metadata is multi-valued, one of the value is returned.
If the metadata does not exist, the default value is returned.- Parameters:
metadataName
- the metadata name.defaultValue
- the default value.- Returns:
- the metadata value as double or the default value if metadata is not set.
- Throws:
AmetysRepositoryException
- if an error occurs.
-
getDoubleArray
double[] getDoubleArray(String metadataName) throws UnknownMetadataException, AmetysRepositoryException
Deprecated.Returns the named metadata's value as double array.- Parameters:
metadataName
- metadata name.- Returns:
- metadata value as double array.
- Throws:
UnknownMetadataException
- if the named metadata does not exist.AmetysRepositoryException
- if an error occurs.
-
getDoubleArray
double[] getDoubleArray(String metadataName, double[] defaultValues) throws AmetysRepositoryException
Deprecated.Returns the named metadata's value as double array.
If the metadata does not exist, the default values are returned.- Parameters:
metadataName
- metadata name.defaultValues
- the default values.- Returns:
- metadata value as double array or the default values if metadata is not set.
- Throws:
AmetysRepositoryException
- if an error occurs.
-
getBoolean
boolean getBoolean(String metadataName) throws UnknownMetadataException, AmetysRepositoryException
Deprecated.Returns the named metadata's value as boolean.
If the metadata is multi-valued, one of the value is returned.
If the metadata does not exist, anUnknownMetadataException
is thrown.- Parameters:
metadataName
- the metadata name.- Returns:
- the metadata value as boolean.
- Throws:
UnknownMetadataException
- if the named metadata does not exist.AmetysRepositoryException
- if an error occurs.
-
getBoolean
boolean getBoolean(String metadataName, boolean defaultValue) throws AmetysRepositoryException
Deprecated.Returns the named metadata's value as boolean.
If the metadata is multi-valued, one of the value is returned.
If the metadata does not exist, the default value is returned.- Parameters:
metadataName
- the metadata name.defaultValue
- the default value.- Returns:
- the metadata value as boolean or the default value if metadata is not set.
- Throws:
AmetysRepositoryException
- if an error occurs.
-
getBooleanArray
boolean[] getBooleanArray(String metadataName) throws UnknownMetadataException, AmetysRepositoryException
Deprecated.Returns the named metadata's value as boolean array.- Parameters:
metadataName
- metadata name.- Returns:
- metadata value as boolean array.
- Throws:
UnknownMetadataException
- if the named metadata does not exist.AmetysRepositoryException
- if an error occurs.
-
getBooleanArray
boolean[] getBooleanArray(String metadataName, boolean[] defaultValues) throws AmetysRepositoryException
Deprecated.Returns the named metadata's value as boolean array.
If the metadata does not exist, the default values are returned.- Parameters:
metadataName
- metadata name.defaultValues
- the default values.- Returns:
- metadata value as boolean array or the default values if metadata is not set.
- Throws:
AmetysRepositoryException
- if an error occurs.
-
getUser
UserIdentity getUser(String metadataName) throws AmetysRepositoryException
Deprecated.Returns the named metadata's value asUserIdentity
.
If the metadata does not exist, anUnknownMetadataException
is thrown.- Parameters:
metadataName
- the metadata name.- Returns:
- the metadata value as user identity.
- Throws:
AmetysRepositoryException
- if an error occurs.
-
getUser
UserIdentity getUser(String metadataName, UserIdentity defaultValue) throws AmetysRepositoryException
Deprecated.Returns the named metadata's value asUserIdentity
.
If the metadata does not exist, the default value is returned.- Parameters:
metadataName
- the metadata name.defaultValue
- the default value.- Returns:
- the metadata value as user identity or the default value if metadata is not set.
- Throws:
AmetysRepositoryException
- if an error occurs.
-
getUserArray
UserIdentity[] getUserArray(String metadataName) throws AmetysRepositoryException
Deprecated.Returns the named metadata's value asUserIdentity
array.- Parameters:
metadataName
- the metadata name.- Returns:
- metadata value as user identity array.
- Throws:
AmetysRepositoryException
- if an error occurs.
-
getUserArray
UserIdentity[] getUserArray(String metadataName, UserIdentity[] defaultValues) throws AmetysRepositoryException
Deprecated.Returns the named metadata's value asUserIdentity
array.
If the metadata does not exist, the default values are returned.- Parameters:
metadataName
- the metadata name.defaultValues
- the default values.- Returns:
- metadata value as user identity array or the default values if metadata is not set.
- Throws:
AmetysRepositoryException
- if an error occurs.
-
getCompositeMetadata
CompositeMetadata getCompositeMetadata(String metadataName) throws UnknownMetadataException, AmetysRepositoryException
Deprecated.Returns the named metadata's value asCompositeMetadata
.
If the metadata is multi-valued, one of the value is returned.
If the metadata does not exist anUnknownMetadataException
is thrown.- Parameters:
metadataName
- the metadata name.- Returns:
- the metadata value as
CompositeMetadata
. - Throws:
UnknownMetadataException
- if the named metadata does not exist.AmetysRepositoryException
- if an error occurs.
-
getObjectCollection
TraversableAmetysObject getObjectCollection(String metadataName) throws AmetysRepositoryException
Deprecated.Returns an object collection metadata as aTraversableAmetysObject
.- Parameters:
metadataName
- the metadata name.- Returns:
- the metadata as a
TraversableAmetysObject
. - Throws:
UnknownMetadataException
- if the named metadata does not exist.AmetysRepositoryException
- if an error occurs.
-
getMetadataNames
String[] getMetadataNames() throws AmetysRepositoryException
Deprecated.Returns an array containing metadata names.- Returns:
- an array containing metadata names.
- Throws:
AmetysRepositoryException
- if an error occurs.
-
isMultiple
boolean isMultiple(String metadataName) throws UnknownMetadataException, AmetysRepositoryException
Deprecated.Test if the given metadata is multiple.- Parameters:
metadataName
- the metadata name.- Returns:
true
if the given metadata is multiple,false
otherwise.- Throws:
UnknownMetadataException
- if the named metadata does not exist.AmetysRepositoryException
- if an error occurs.
-
copyTo
void copyTo(ModifiableCompositeMetadata metadata) throws AmetysRepositoryException
Deprecated.Copy the currentCompositeMetadata
to the given composite metadata.- Parameters:
metadata
- The parent composite metadata. Can not be null.- Throws:
AmetysRepositoryException
- if an error occurs.
-
-