1 31 32 package org.opencms.loader; 33 34 import org.opencms.file.CmsObject; 35 import org.opencms.file.CmsPropertyDefinition; 36 import org.opencms.file.CmsResource; 37 import org.opencms.main.CmsException; 38 import org.opencms.xml.I_CmsXmlDocument; 39 import org.opencms.xml.content.CmsXmlContentFactory; 40 41 import javax.servlet.ServletRequest ; 42 43 52 public class CmsXmlContentLoader extends A_CmsXmlDocumentLoader { 53 54 55 public static final int RESOURCE_LOADER_ID = 10; 56 57 60 public int getLoaderId() { 61 62 return RESOURCE_LOADER_ID; 63 } 64 65 71 public String getResourceLoaderInfo() { 72 73 return Messages.get().getBundle().key(Messages.GUI_LOADER_XMLCONTENT_DEFAULT_DESC_0); 74 } 75 76 79 protected I_CmsXmlDocument unmarshalXmlDocument(CmsObject cms, CmsResource resource, ServletRequest req) 80 throws CmsException { 81 82 return CmsXmlContentFactory.unmarshal(cms, resource, req); 83 } 84 85 88 protected String getTemplatePropertyDefinition() { 89 90 return CmsPropertyDefinition.PROPERTY_TEMPLATE_ELEMENTS; 91 } 92 } | Popular Tags |