Package org.ametys.odf.contenttype
Class ODFContentType
java.lang.Object
org.ametys.runtime.plugin.component.AbstractLogEnabled
org.ametys.cms.contenttype.AbstractContentTypeDescriptor
org.ametys.cms.contenttype.DefaultContentType
org.ametys.odf.contenttype.ODFContentType
- All Implemented Interfaces:
ContentType
,ContentTypeDescriptor
,MetadataDefinitionHolder
,Model
,ModelItemAccessor
,ModelItemContainer
,LogEnabled
,PluginAware
,Disposable
,Configurable
,Contextualizable
,Serviceable
,ThreadSafe
The ODF content type
-
Nested Class Summary
Nested classes/interfaces inherited from class org.ametys.cms.contenttype.DefaultContentType
DefaultContentType.AnnotableDefinition, DefaultContentType.MetadataAndRepeaterDefinitionParser, DefaultContentType.RestrictedDefinition, DefaultContentType.RestrictedMetadataDefinition, DefaultContentType.RestrictedRepeaterDefinition, DefaultContentType.RestrictedRichTextDefinition
-
Field Summary
Modifier and TypeFieldDescriptionprotected ODFContentTypeMetadataManager
The ODF content type metadata managerprotected ShareableCourseHelper
The shareable course helperprotected ShareableCourseStatusHelper
The shareable course status helperFields inherited from class org.ametys.cms.contenttype.DefaultContentType
__GLOBAL_VALIDATOR_ROLE_PREFIX, _abstract, _attributeDefinitionParser, _cocoonContext, _compositeDefinitionParser, _context, _defaultWorkflowName, _dublinCoreAttributeDefinitionParser, _globalValidators, _hierarchicalSimpleContentsHelper, _indexingModel, _manager, _metadata, _modelItems, _overriddenAttributes, _overriddenViews, _parentAttributeDefinition, _repeaterDefinitionParser, _restrictedModelItemHelper, _richTextOutgoingReferencesExtractor, _richTextTransformer, _richTextUpdater, _right, _tags, _views
Fields inherited from class org.ametys.cms.contenttype.AbstractContentTypeDescriptor
_allMetadataSets, _category, _contentTypesHelper, _contentTypesParserHelper, _cssFiles, _cTypeEP, _dcProvider, _defaultTitle, _description, _iconDecorator, _iconGlyph, _id, _label, _largeIcon, _mediumIcon, _metadataSets, _pluginName, _smallIcon, _srcResolver, _superTypeIds
Fields inherited from interface org.ametys.cms.contenttype.ContentType
TAG_MIXIN, TAG_PRIVATE, TAG_REFERENCE_TABLE, TAG_RENDERABLE_FERENCE_TABLE
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
canRead
(Content content, AttributeDefinition definition) Determine whether an attribute can be read at this time.boolean
canRead
(Content content, MetadataDefinition metadataDef) Deprecated.boolean
canWrite
(Content content, AttributeDefinition definition) Determine whether an attribute can be written at this time.boolean
canWrite
(Content content, MetadataDefinition metadataDef) Deprecated.getAdditionalData
(Content content) Get the additional data relative to itsContentType
.void
service
(ServiceManager manager) Methods inherited from class org.ametys.cms.contenttype.DefaultContentType
_addSemanticAnnotations, _checkAttributeTypes, _checkAttributeTypes, _checkContentAttributes, _checkContentTypeId, _checkContentTypeSimplicity, _checkMetadataDefinition, _checkMetadataTypes, _checkMutualReferences, _computeIndexingModelReferences, _configureAttributeDefinitions, _configureCustomIndexingFields, _configureCustomMetadataIndexingFields, _configureDefaultWorkflowName, _configureGlobalValidators, _configureIndexingModel, _configureMetadataIndexingFields, _configureParentContentType, _configureViews, _getApplicableAttributes, _getApplicableViews, _getContentTypeReservedAttributeNameExtensionPoint, _getRestrictionsForPath, _getSemanticAnnotations, _parseAllAttributes, _parseAllMetadatas, _parseDublinCoreAttributes, _parseDublinCoreMetadata, _parseGlobalValidators, _parseMetadata, _parseModelItem, _parseTags, _parseViews, _resolveViewReferences, _resolveViewReferences, configure, contextualize, dispose, getDefaultWorkflowName, getFamilyId, getGlobalValidators, getIndexingFieldDefinitions, getIndexingModel, getMetadataDefinition, getMetadataDefinitionByPath, getMetadataNames, getModelItems, getOverriddenAttributes, getOverriddenViews, getOverridenConfiguration, getParentAttributeDefinition, getRichTextUpdater, getRight, getRootConfiguration, getTags, getView, getViewNames, hasMetadataDefinition, hasTag, isAbstract, isMixin, isMultilingual, isPrivate, isReferenceTable, isSimple, postInitialize, saxContentTypeAdditionalData, toString
Methods inherited from class org.ametys.cms.contenttype.AbstractContentTypeDescriptor
_configureCSSFiles, _configureIcons, _configureLabels, _configureMetadataSets, _configureSuperTypes, _fillMetadataSetDublinCore, _fillMetadataSetElement, _getApplicableMetadataSets, _parseMetadataSet, _parseMetadataSets, getCategory, getCSSFiles, getDefaultTitle, getDescription, getEditionMetadataSetNames, getIconDecorator, getIconGlyph, getId, getLabel, getLargeIcon, getMediumIcon, getMetadataSetForEdition, getMetadataSetForView, getPluginName, getSmallIcon, getSupertypeIds, getViewMetadataSetNames, setPluginInfo
Methods inherited from class org.ametys.runtime.plugin.component.AbstractLogEnabled
getLogger, setLogger
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.ametys.cms.contenttype.ContentType
getViewNames
Methods inherited from interface org.ametys.cms.contenttype.ContentTypeDescriptor
getCategory, getCSSFiles, getDefaultCatalog, getDefaultTitle, getDescription, getEditionMetadataSetNames, getIconDecorator, getIconGlyph, getIconPath, getId, getLabel, getLargeIcon, getMediumIcon, getMetadataSetForEdition, getMetadataSetForView, getPluginName, getSmallIcon, getSupertypeIds, getViewMetadataSetNames
Methods inherited from interface org.ametys.runtime.model.ModelItemAccessor
getChild, getModelItem, hasModelItem
-
Field Details
-
_odfContentTypeMetadataManager
The ODF content type metadata manager
-
-
Constructor Details
-
ODFContentType
public ODFContentType()
-
-
Method Details
-
service
- Specified by:
service
in interfaceServiceable
- Overrides:
service
in classDefaultContentType
- Throws:
ServiceException
-
canRead
public boolean canRead(Content content, AttributeDefinition definition) throws AmetysRepositoryException Description copied from interface:ContentType
Determine whether an attribute can be read at this time. Method called byAttributeDefinition.canRead(Content)
to do some other checks, depending on the content type- Parameters:
content
- The content where attribute is to be read on. Can be null, on content creation.definition
- the attribute definition- Returns:
true
if the current user is allowed to read the attribute of this content.- Throws:
AmetysRepositoryException
- if an error occurs while accessing the content.
-
canWrite
public boolean canWrite(Content content, AttributeDefinition definition) throws AmetysRepositoryException Description copied from interface:ContentType
Determine whether an attribute can be written at this time. Method called byAttributeDefinition.canWrite(Content)
to do some other checks, depending on the content type- Parameters:
content
- The content where attribute is to be written on. Can be null, on content creation.definition
- the attribute definition- Returns:
true
if the current user is allowed to write the attribute of this content.- Throws:
AmetysRepositoryException
- if an error occurs while accessing the content.
-
canWrite
@Deprecated public boolean canWrite(Content content, MetadataDefinition metadataDef) throws AmetysRepositoryException Deprecated.Description copied from interface:ContentType
Determine whether a metadata can be written at this time.- Specified by:
canWrite
in interfaceContentType
- Overrides:
canWrite
in classDefaultContentType
- Parameters:
content
- The content where metadata is to be written on. Can be null, on content creation.metadataDef
- the metadata definition- Returns:
true
if the current user is allowed to write the metadata of this content.- Throws:
AmetysRepositoryException
- if an error occurs while accessing the content.
-
canRead
@Deprecated public boolean canRead(Content content, MetadataDefinition metadataDef) throws AmetysRepositoryException Deprecated.Description copied from interface:ContentType
Determine whether a metadata can be read at this time.- Specified by:
canRead
in interfaceContentType
- Overrides:
canRead
in classDefaultContentType
- Parameters:
content
- The content where metadata is to be read on. Can be null, on content creation.metadataDef
- the metadata definition- Returns:
true
if the current user is allowed to read the metadata of this content.- Throws:
AmetysRepositoryException
- if an error occurs while accessing the content.
-
getAdditionalData
Description copied from interface:ContentType
Get the additional data relative to itsContentType
. These additional data are delivered to client side.- Specified by:
getAdditionalData
in interfaceContentType
- Overrides:
getAdditionalData
in classDefaultContentType
- Parameters:
content
- The content- Returns:
- the additional properties in a Map
-