|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.endeca.portal.metadata.AbstractMetadataManager<FrameworkSetting> com.endeca.portal.metadata.framework.FrameworkSettingManager
public class FrameworkSettingManager
Encapsulates DB-interaction methods specific to Discovery Framework settings
Field Summary | |
---|---|
static java.lang.String |
TYPE_FRAMEWORK
Represents the "type" value for DF-core settings |
static java.lang.String |
TYPE_FRAMEWORK_KEYPREFIX
Represents the key prefix for all framework settings |
Method Summary | ||
---|---|---|
java.util.List<FrameworkSetting> |
getAllFrameworkSettings()
Returns all Discovery Framework core settings. |
|
FrameworkSetting |
getFrameworkSettingByKey(java.lang.String key)
Returns a Discovery Framework core setting by its key. |
|
java.lang.String |
getFrameworkSettingValueByKey(java.lang.String key,
java.lang.String defaultValue)
Returns the value of a Discovery Framework core setting by its key. |
|
static FrameworkSettingManager |
getInstance()
Gets a FrameworkSettingManager instance. |
|
FrameworkSetting |
getOrSetFrameworkRecordByKey(java.lang.String key,
FrameworkSetting defaultSetting)
Returns a Discovery Framework core setting if it exists and writes (then returns) a specified record to the db otherwise |
|
FrameworkSetting |
objectFromMetadataRecord(com.endeca.portal.liferay.ext.metadata.model.MetadataRecord record)
Converts a Liferay record to a Framework Setting |
|
|
propertyFromMetadataPropertyRecord(com.endeca.portal.liferay.ext.metadata.model.MetadataPropertyRecord record)
Returns null; Framework settings 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_FRAMEWORK
public static final java.lang.String TYPE_FRAMEWORK_KEYPREFIX
Method Detail |
---|
public FrameworkSetting getFrameworkSettingByKey(java.lang.String key)
key
- the key of the setting to retrieve
public java.util.List<FrameworkSetting> getAllFrameworkSettings()
public java.lang.String getFrameworkSettingValueByKey(java.lang.String key, java.lang.String defaultValue)
key
- the key of the setting to retrievedefaultValue
- the value to use if the setting was not found
public FrameworkSetting getOrSetFrameworkRecordByKey(java.lang.String key, FrameworkSetting defaultSetting) throws MetadataException
key
- the key of the setting to retrievedefaultSetting
- the record to write if the setting was not found
MetadataException
- if a record could not be retrieved or setpublic static FrameworkSettingManager getInstance()
public FrameworkSetting objectFromMetadataRecord(com.endeca.portal.liferay.ext.metadata.model.MetadataRecord record)
objectFromMetadataRecord
in interface MetadataManager<FrameworkSetting>
objectFromMetadataRecord
in class AbstractMetadataManager<FrameworkSetting>
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<FrameworkSetting>
propertyFromMetadataPropertyRecord
in class AbstractMetadataManager<FrameworkSetting>
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 |