AnsweredAssumed Answered

OpenCMIS Create Custom Content

Question asked by johnpneal on Jan 6, 2011
Latest reply on Jan 13, 2011 by johnpneal
I am new to OpenCMIS.  I am able to create folders and documents.  Alfresco also has content types either pre-defined or custom.  I want to create content types of either kind but am having difficulty finding out a way to do this in OpenCMIS.  For example, here is a test custom type:


<?xml version="1.0" encoding="UTF-8"?>
<!– Definition of Hotel Solution Model –>
<model name="hs:HotelSolution" xmlns="http://www.alfresco.org/model/dictionary/1.0">

   <!– Optional meta-data about the model –>  
   <description>Hotel Solution Content Model</description>
   <author>Development Team</author>
   <version>1.0</version>

   <imports>
        <!– Import Alfresco Dictionary Definitions –>
      <import uri="http://www.alfresco.org/model/dictionary/1.0" prefix="d"/>
      <!– Import Alfresco Content Domain Model Definitions –>
      <import uri="http://www.alfresco.org/model/content/1.0" prefix="cm"/>
   </imports>

   <!– Introduction of new namespaces defined by this model –>
   <namespaces>
      <namespace uri="http://www.ihgmerlin.com/hotelSolution" prefix="hs"/>
   </namespaces>
  
   <types>
  
      <!– Definition of new Content Type: Idea Content –>
      <type name="hs:IdeaContent">
         <title>Hotel Solution Idea Content</title>
         <parent>cm:content</parent>
         <properties>
            <property name="hs:name">
               <type>d:text</type>
            </property>
            <property name="hs:hotel">
               <type>d:text</type>
            </property>
            <property name="hs:title">
               <type>d:text</type>
            </property>
         </properties>
         <associations/>
      </type>
    </types>
    <aspects/>
</model>

I want to programatically create this content type using OpenCMIS, filling in the correct propeties, etc., can anyone help me with this with a code example or a link that can help out?

Outcomes