public class MetadataSetDefGenerator extends ServiceableGenerator
Generator
for rendering the structure of a metadata setModifier and Type | Field and Description |
---|---|
protected ContentHelper |
_contentHelper
The content helper
|
protected ContentTypeExtensionPoint |
_contentTypeExtensionPoint
Content type extension point.
|
protected ContentTypesHelper |
_contentTypesHelper
Helper for content types
|
protected CurrentUserProvider |
_currentUserProvider
The current user provider
|
protected MetadataManager |
_metadataManager
Metadata manager.
|
protected RightManager |
_rightManager
Rights manager
|
manager
objectModel, parameters, resolver, source
contentHandler, EMPTY_CONTENT_HANDLER, lexicalHandler, xmlConsumer
Constructor and Description |
---|
MetadataSetDefGenerator() |
Modifier and Type | Method and Description |
---|---|
protected MetadataDefinition |
_getMetadataDefinition(Content content,
MetadataDefinition parentMetadataDefinition,
String metadataName)
Retrieves a sub metadata definition from a content type or
a parent metadata definition.
|
private void |
_saxAnnotableDefinition(Content content,
AbstractMetadataSetElement metadataSetElement,
RichTextMetadataDefinition metaDef)
SAX the annotations of a definition
|
private void |
_saxCompositeDefinition(Content content,
AbstractMetadataSetElement metadataSetElement,
MetadataDefinition metaDef)
Sax a composite definition
|
private void |
_saxEnumeration(Enumerator enumerator) |
protected void |
_saxMetadataDefinition(Content content,
AbstractMetadataSetElement metadataSetElement,
MetadataDefinition metaDef)
Sax the metadata definition
|
protected void |
_saxMetadataSet(Content content,
String metadataSetName,
boolean isEditionMetadataSet)
SAX metadata set structure
|
protected void |
_saxMetadataSetElement(Content content,
MetadataDefinition metadataDefinition,
AbstractMetadataSetElement metadataSetElement)
SAX metadata set element.
|
void |
generate() |
void |
service(ServiceManager serviceManager) |
dispose
recycle, setup
setConsumer, setContentHandler, setLexicalHandler
enableLogging, getLogger, setupLogger, setupLogger, setupLogger
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
setConsumer
protected ContentTypeExtensionPoint _contentTypeExtensionPoint
protected MetadataManager _metadataManager
protected ContentTypesHelper _contentTypesHelper
protected RightManager _rightManager
protected CurrentUserProvider _currentUserProvider
protected ContentHelper _contentHelper
public MetadataSetDefGenerator()
public void service(ServiceManager serviceManager) throws ServiceException
service
in interface Serviceable
service
in class ServiceableGenerator
ServiceException
public void generate() throws IOException, SAXException, ProcessingException
protected void _saxMetadataSet(Content content, String metadataSetName, boolean isEditionMetadataSet) throws SAXException, ProcessingException, IOException
content
- the content.metadataSetName
- The name of the metadata set to saxisEditionMetadataSet
- True to use the edit metadata setSAXException
- if an error occurs while SAXing.IOException
- if an error occurs.ProcessingException
- if an error occurs.protected void _saxMetadataSetElement(Content content, MetadataDefinition metadataDefinition, AbstractMetadataSetElement metadataSetElement) throws SAXException
content
- the content.metadataDefinition
- the metadata definition.metadataSetElement
- the metadata set element.SAXException
- if an error occurs while SAXing.protected MetadataDefinition _getMetadataDefinition(Content content, MetadataDefinition parentMetadataDefinition, String metadataName)
content
- the content.parentMetadataDefinition
- the parent metadata definition.metadataName
- the metadata name.null
otherwise.protected void _saxMetadataDefinition(Content content, AbstractMetadataSetElement metadataSetElement, MetadataDefinition metaDef) throws SAXException
content
- The contentmetadataSetElement
- The metadata set elementmetaDef
- The metadata definitionSAXException
- if an error occurs while SAXing.private void _saxEnumeration(Enumerator enumerator) throws SAXException
SAXException
private void _saxAnnotableDefinition(Content content, AbstractMetadataSetElement metadataSetElement, RichTextMetadataDefinition metaDef) throws SAXException
content
- the content.metadataSetElement
- the metadata set element.metaDef
- the metadata definition.SAXException
- if an error occurs while SAXing.private void _saxCompositeDefinition(Content content, AbstractMetadataSetElement metadataSetElement, MetadataDefinition metaDef) throws SAXException
content
- the content.metadataSetElement
- the metadata set element.metaDef
- the metadata definition.SAXException
- if an error occurs while SAXing.