public class MediaDefinition extends SystemObjectDefinition
MediaDefinition mdef = new MediaDefinition(session);Note: All the methods of interest are actually in the base class, LibraryObjectDefinition.
// set the name of the new media mdef.setName("mediatype");
// create it Media mediatype = session.createMedia(mdef);
LibraryObjectDefinition
,
Media
,
LibraryObjectDefinition.setName(java.lang.String)
,
Serialized FormLibraryObjectDefinition.EnumToIntegerCode, LibraryObjectDefinition.LookupByName
m_Attributes, m_ClassObjectName, m_ClassObjectValue, m_ContentSpecifications, m_DefinitionLists, m_Definitions, m_EnclosedDefinition, m_Id, m_Options, m_ReadOnly, m_ReferenceAttributes, m_Session, m_SystemOptions
Constructor and Description |
---|
MediaDefinition(LibrarySessionInterface session)
Construct a definition explicitly capturing the
session.
|
MediaDefinition(LibrarySessionInterface session,
String className)
Construct a definition, explicitly capturing the
session and setting the initial classobject.
|
Modifier and Type | Method and Description |
---|---|
void |
applySettings(AttributeValueTable avt)
Applies settings from the specified table.
|
String |
getAlterTableSuffix()
Gets the string appended to the ALTER TABLE statement executed to add a
column to a content table.
|
String |
getCreateTableSuffix()
Gets the string appended to the CREATE TABLE statement executed to create
a new content table.
|
void |
setAlterTableSuffix(String suffix)
Sets the string appended to the ALTER TABLE statement executed to add a
column to a content table.
|
void |
setCreateTableSuffix(String suffix)
Sets the string appended to the CREATE TABLE statement executed to create
a new content table.
|
static MediaDefinition |
toMediaDefinition(LibraryObjectDefinition lodef)
Casts the specified LibraryObjectDefinition to a MediaDefinition.
|
static MediaDefinition |
toMediaDefinition(LibraryObjectDefinition lodef,
boolean enforceCompat)
Casts the specified LibraryObjectDefinition to a MediaDefinition.
|
addCategoryDefinition, addCategoryDefinitionForUpdate, addCategoryDefinitions, addCategoryForDelete, getCategoriesForDelete, getCategoryDefinitions, getCategoryDefinitionsForUpdate, getCreateCategoriesServerSideOption, removeCategoriesForDelete, removeCategoryDefinitions, removeCategoryDefinitionsForUpdate, setCategoryDefinitions, setCreateCategoriesServerSideOption, toSystemObjectDefinition, toSystemObjectDefinition
addDefinition, addDefinitions, addProperty, addPropertyDefinition, addPropertyDefinition, addPropertyDefinitions, addPropertyDefinitions, addSimplePropertyDefinition, addSimplePropertyDefinition, addSimplePropertyDefinitions, addSimplePropertyDefinitions, applyEnumSetting, applyEnumSetting, applyMapSetting, applyMapSetting, applyObjectArraySetting, applyObjectArraySetting, applyObjectSetting, applyObjectSetting, applySetting, applySetting, captureSession, captureSession, captureSession, clone, constructInstance, constructInstance, constructInstance, copyInto, deriveObjectArraySetting, deriveObjectSetting, getAttribute, getAttribute, getAttributes, getAttributes, getAttributesSorted, getClassId, getClassObject, getClassObjectValue, getContentSpecification, getContentSpecificationKeys, getCopiedObjectValue, getDefinition, getDefinitionClassName, getDefinitionKeys, getDefinitionListKeys, getDefinitions, getId, getLibrarySession, getName, getOption, getOptionAsAttributeValue, getOptionKeys, getPolicyMode, getPropertyDefinitions, getReferenceAttribute, getReferenceAttributes, getServerDefinition, getSession, getSimplePropertyDefinitions, getSLibrarySession, getStringAttribute, getSystemOption, getSystemOptionAsAttributeValue, getSystemOptionAsBoolean, getSystemOptionKeys, getWriteableInstance, isReadOnly, prepareForDefinitionObject, processSimplePropertiesForCreate, processSimplePropertiesForUpdate, removeAttribute, removeContentSpecification, removeDefinition, removeDefinitions, removeOption, removePropertyDefinitions, removeReferenceAttribute, removeSimplePropertyDefinitions, removeSystemOption, reset, resolve, setAttribute, setAttribute, setAttribute, setAttributeByUpperCaseName, setAttributeByUpperCaseName, setAttributePolicyMode, setAttributes, setClassId, setClassname, setClassObject, setClassObjectValue, setContentSpecification, setCopiedObjectValue, setDefinition, setDefinitions, setId, setName, setOption, setReadOnly, setReferenceAttribute, setReferenceAttribute, setSession, setSimplePropertyDefinitions, setSystemOption, unresolve, verifySession
public MediaDefinition(LibrarySessionInterface session) throws IfsException
session
- the current sessionIfsException
- if the operation failspublic MediaDefinition(LibrarySessionInterface session, String className) throws IfsException
session
- the current sessionclassName
- the initial class nameIfsException
- if the operation failspublic void applySettings(AttributeValueTable avt) throws IfsException
applySettings
in class SystemObjectDefinition
avt
- the table having the definition settingsIfsException
- if the operation failspublic void setCreateTableSuffix(String suffix) throws IfsException
suffix
- the suffix, or null for noneIfsException
- if the operation failspublic String getCreateTableSuffix() throws IfsException
IfsException
- if the operation failspublic void setAlterTableSuffix(String suffix) throws IfsException
suffix
- the suffix, or null for noneIfsException
- if the operation failspublic String getAlterTableSuffix() throws IfsException
IfsException
- if the operation failspublic static MediaDefinition toMediaDefinition(LibraryObjectDefinition lodef) throws IfsException
Returns null if the specified definition is not a MediaDefinition, or if the specified definition is null.
lodef
- the definitionIfsException
- is not currently thrownpublic static MediaDefinition toMediaDefinition(LibraryObjectDefinition lodef, boolean enforceCompat) throws IfsException
Returns the MediaDefinition, or null if the specified definition
is null. If the cast fails, returns null if enforceCompat
is false or throws IfsException if enforceCompat
is true.
lodef
- the definition to castenforceCompat
- whether to throw an exception if the cast failsIfsException
- (IFS-10822) if the operation failsCopyright © 2023. All rights reserved.