|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.endeca.portal.metadata.AbstractMetadataManager<AttributeDisplayName> com.endeca.portal.metadata.attributes.AttributeDisplayNameManager
public class AttributeDisplayNameManager
Encapsulates DB-interaction methods specific to display names for attributes
Field Summary | |
---|---|
static java.lang.String |
TYPE_ATTR_DISPLAY_NAME
Represents the "type" value for an attribute's display name |
Method Summary | ||
---|---|---|
java.util.List<AttributeDisplayName> |
getAllDisplayNames()
Returns all attribute display names. |
|
AttributeDisplayName |
getDisplayNameByKey(java.lang.String dataSourceId,
java.lang.String key)
Returns an attribute display name, associated with a given data source, by its key |
|
java.util.List<AttributeDisplayName> |
getDisplayNamesByDataSource(java.lang.String dataSourceId)
Returns a list of attribute display names associated with a given data source |
|
java.lang.String |
getDisplayNameValueByKey(java.lang.String dataSourceId,
java.lang.String key,
java.lang.String defaultValue)
Returns the value of an attribute display name, associated with a given data source, by its key. |
|
static AttributeDisplayNameManager |
getInstance()
Gets a AttributeDisplayNameManager instance. |
|
AttributeDisplayName |
getOrSetDisplayNameByKey(java.lang.String dataSourceId,
java.lang.String key,
AttributeDisplayName defaultAttrDispName)
Returns an attribute display name, associated with a given data source, if it exists and writes (then returns) a specified record to the db otherwise |
|
AttributeDisplayName |
objectFromMetadataRecord(com.endeca.portal.liferay.ext.metadata.model.MetadataRecord record)
Given a base Liferay record, return a Metadata Object; subclasses must implement this method. |
|
|
propertyFromMetadataPropertyRecord(com.endeca.portal.liferay.ext.metadata.model.MetadataPropertyRecord record)
Returns null; Attribute display names do not have child Metadata Properties |
Methods inherited from class com.endeca.portal.metadata.AbstractMetadataManager |
---|
getObject, getObjectById, getObjects, getProperties, getProperty, handleObjectPropertyPersistence, objectsFromMetadataRecords, persist, persist, persistProperties, persistProperty, propertiesFromMetadataPropertyRecords, removeObjectById, removePropertyById |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String TYPE_ATTR_DISPLAY_NAME
Method Detail |
---|
public java.util.List<AttributeDisplayName> getAllDisplayNames()
public java.util.List<AttributeDisplayName> getDisplayNamesByDataSource(java.lang.String dataSourceId)
dataSourceId
- the data source ID
public AttributeDisplayName getDisplayNameByKey(java.lang.String dataSourceId, java.lang.String key)
dataSourceId
- the data source IDkey
- the name of the attribute for which a display name should be retrieved
public java.lang.String getDisplayNameValueByKey(java.lang.String dataSourceId, java.lang.String key, java.lang.String defaultValue)
dataSourceId
- the data source IDkey
- the name of the attribute for which a display name should be retrieveddefaultValue
- the value to use if the attribute display name was not found
public AttributeDisplayName getOrSetDisplayNameByKey(java.lang.String dataSourceId, java.lang.String key, AttributeDisplayName defaultAttrDispName) throws MetadataException
dataSourceId
- the data source IDkey
- the name of the attribute for which a display name should be retrieveddefaultAttrDispName
- the object to write if the attribute display name was not found
MetadataException
- if a record could not be retrieved or setpublic static AttributeDisplayNameManager getInstance()
public AttributeDisplayName objectFromMetadataRecord(com.endeca.portal.liferay.ext.metadata.model.MetadataRecord record)
AbstractMetadataManager
objectFromMetadataRecord
in interface MetadataManager<AttributeDisplayName>
objectFromMetadataRecord
in class AbstractMetadataManager<AttributeDisplayName>
record
- the base Liferay record
MetadataManager.objectFromMetadataRecord(MetadataRecord)
public <S extends MetadataProperty> S propertyFromMetadataPropertyRecord(com.endeca.portal.liferay.ext.metadata.model.MetadataPropertyRecord record)
propertyFromMetadataPropertyRecord
in interface MetadataManager<AttributeDisplayName>
propertyFromMetadataPropertyRecord
in class AbstractMetadataManager<AttributeDisplayName>
S
- an instance of a Metadata Property extensionrecord
- the base Liferay record
MetadataManager.propertyFromMetadataPropertyRecord(MetadataPropertyRecord)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |