📄 i_cmsxmltemplate.java
字号:
/*
* File : $Source: /usr/local/cvs/opencms/src/com/opencms/template/I_CmsXmlTemplate.java,v $
* Date : $Date: 2003/01/20 23:59:21 $
* Version: $Revision: 1.9 $
*
* This library is part of OpenCms -
* the Open Source Content Mananagement System
*
* Copyright (C) 2001 The OpenCms Group
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* For further information about OpenCms, please see the
* OpenCms Website: http://www.opencms.org
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
package com.opencms.template;
import com.opencms.file.*;
import com.opencms.core.*;
import java.util.*;
/**
* Interface for OpenCms XML template classes.
* <P>
* All methods extending the functionality of the common
* template class interface to the special behaviour
* of XML template classes may be defined here.
* <P>
* Primarily, this interface is important for the launcher,
* NOT for the template engine.
* The CmsXmlLauncher can launch all templates that
* implement the I_CmsXmlTemplate interface.
* <P>
* For subtemplates, the I_CmsTemplate interface is
* all that must be implemented, so you can load all kind
* of templates (eg. type I_CmsDumpTemplate) as subtemplate.
*
* @author Alexander Lucas
* @version $Revision: 1.9 $ $Date: 2003/01/20 23:59:21 $
*/
public interface I_CmsXmlTemplate extends I_CmsTemplate {
/**
* Reads in the template file and starts the XML parser for the expected
* content type.
* <P>
* Every extending class not using CmsXmlTemplateFile as content type
* should override this method.
*
* @param cms CmsObject Object for accessing system resources.
* @param templateFile Filename of the template file.
* @param elementName Element name of this template in our parent template.
* @param parameters Hashtable with all template class parameters.
* @param templateSelector template section that should be processed.
*/
public CmsXmlTemplateFile getOwnTemplateFile(CmsObject cms, String templateFile, String elementName, Hashtable parameters, String templateSelector) throws CmsException;
/**
* Handles any occurence of an "ELEMENT" tag.
* <P>
* Every XML template class should use CmsXmlTemplateFile as
* the interface to the XML file. Since CmsXmlTemplateFile is
* an extension of A_CmsXmlContent by the additional tag
* "ELEMENT" this user method ist mandatory.
*
* @param cms CmsObject Object for accessing system resources.
* @param tagcontent Unused in this special case of a user method. Can be ignored.
* @param doc Reference to the A_CmsXmlContent object the initiating XLM document.
* @param userObj Hashtable with parameters.
* @return String or byte[] with the content of this subelement.
* @throws CmsException
*/
public Object templateElement(CmsObject cms, String tagcontent, A_CmsXmlContent doc, Object userObject) throws CmsException;
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -