com.arsdigita.cms.installer.xml
Class ContentTypeInitializer

java.lang.Object
  extended bycom.arsdigita.kernel.BaseInitializer
      extended bycom.arsdigita.cms.installer.xml.ContentTypeInitializer
All Implemented Interfaces:
com.arsdigita.initializer.Initializer

public class ContentTypeInitializer
extends com.arsdigita.kernel.BaseInitializer

Parses XML file definition of content types and loads them to the database. The XML config looks like the example below, the "parentType" and "name" attributes are optional, and only required for creating User Defined ContentTypes. Label corresponds to ContentType's label and can be multiple words, and "name" to DynamicObject's name property, and must be a single word. The objectType attribute is ignored for UDCTs, as it gets dynamically generated. UDCT Copyright

 <ccm:content-types>
   <ccm:content-type 
             name="Copyright"
             label="UDCT Copyright"
             parentType="com.arsdigita.cms.contenttypes.Address"
             classname="com.arsdigita.cms.contenttypes.Address"
             description="Copyright for storing copyright information" 
             objectType="com.arsdigita.cms.contentTypes.Address" >
    
      <ccm:authoring-kit>
      </ccm:authoring-kit>
   </ccm:content-type>
 </ccm:content-types>
Initializer
  init com.arsdigita.cms.installer.ContentTypeInitializer {
      contentTypes = {
          "/WEB-INF/content-types/Article.xml"
      };
  }

Author:
Nobuko Asakai
See Also:
XMLContentTypeHandler

Field Summary
static String CONTENT_TYPES
           
 
Fields inherited from interface com.arsdigita.initializer.Initializer
versionId
 
Constructor Summary
ContentTypeInitializer()
           
 
Method Summary
protected  void doShutdown()
           
protected  void doStartup()
           
 com.arsdigita.initializer.Configuration getConfiguration()
           
 
Methods inherited from class com.arsdigita.kernel.BaseInitializer
shutdown, startup
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CONTENT_TYPES

public static final String CONTENT_TYPES
See Also:
Constant Field Values
Constructor Detail

ContentTypeInitializer

public ContentTypeInitializer()
Method Detail

getConfiguration

public com.arsdigita.initializer.Configuration getConfiguration()

doShutdown

protected void doShutdown()

doStartup

protected void doStartup()
                  throws com.arsdigita.initializer.InitializationException
Throws:
com.arsdigita.initializer.InitializationException


Copyright (c) 2004 Red Hat, Inc. Corporation. All Rights Reserved. Generated at July 21 2004:2352 UTC