00001 /* 00002 * Licensed to the Apache Software Foundation (ASF) under one 00003 * or more contributor license agreements. See the NOTICE file 00004 * distributed with this work for additional information 00005 * regarding copyright ownership. The ASF licenses this file 00006 * to you under the Apache License, Version 2.0 (the "License"); 00007 * you may not use this file except in compliance with the License. 00008 * You may obtain a copy of the License at 00009 * 00010 * http://www.apache.org/licenses/LICENSE-2.0 00011 * 00012 * Unless required by applicable law or agreed to in writing, software 00013 * distributed under the License is distributed on an "AS IS" BASIS, 00014 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 00015 * See the License for the specific language governing permissions and 00016 * limitations under the License. 00017 */ 00018 #if !defined(XALAN_ELEMLITERALRESULT_HEADER_GUARD) 00019 #define XALAN_ELEMLITERALRESULT_HEADER_GUARD 00020 00021 00022 00023 // Base include file. Must be first. 00024 #include <xalanc/XSLT/XSLTDefinitions.hpp> 00025 00026 00027 00028 // Base class header file. 00029 #include <xalanc/XSLT/ElemUse.hpp> 00030 00031 00032 00033 XALAN_CPP_NAMESPACE_BEGIN 00034 00035 00036 00037 class AVT; 00038 00039 00040 00041 class ElemLiteralResult: public ElemUse 00042 { 00043 public: 00044 00045 /** 00046 * Construct an object corresponding to a literal result element 00047 * 00048 * @param constructionContext context for construction of object 00049 * @param stylesheetTree stylesheet containing element 00050 * @param name name of element 00051 * @param atts list of attributes for element 00052 * @param lineNumber line number in document 00053 * @param columnNumber column number in document 00054 */ 00055 ElemLiteralResult( 00056 StylesheetConstructionContext& constructionContext, 00057 Stylesheet& stylesheetTree, 00058 const XalanDOMChar* name, 00059 const AttributeListType& atts, 00060 XalanFileLoc lineNumber, 00061 XalanFileLoc columnNumber); 00062 00063 virtual 00064 ~ElemLiteralResult(); 00065 00066 // These methods are inherited from ElemUse ... 00067 00068 virtual const XalanDOMString& 00069 getElementName() const; 00070 00071 virtual void 00072 postConstruction( 00073 StylesheetConstructionContext& constructionContext, 00074 const NamespacesHandler& theParentHandler); 00075 00076 virtual bool 00077 isAttrOK( 00078 const XalanDOMChar* attrName, 00079 const AttributeListType& atts, 00080 XalanSize_t which, 00081 StylesheetConstructionContext& constructionContext) const; 00082 00083 #if !defined(XALAN_RECURSIVE_STYLESHEET_EXECUTION) 00084 virtual const ElemTemplateElement* 00085 startElement(StylesheetExecutionContext& executionContext) const; 00086 00087 virtual void 00088 endElement(StylesheetExecutionContext& executionContext) const; 00089 00090 virtual void 00091 evaluateAVTs(StylesheetExecutionContext& executionContext) const; 00092 #else 00093 virtual void 00094 execute(StylesheetExecutionContext& executionContext) const; 00095 #endif 00096 00097 protected: 00098 00099 /** 00100 * Do common initialization. 00101 * 00102 * @param constructionContext The current onstruction context. 00103 * @param stylesheetTree The stylesheet containing the element. 00104 * @param name The name of the element. 00105 * @param atts The list of attributes for the element. 00106 */ 00107 void 00108 init( 00109 StylesheetConstructionContext& constructionContext, 00110 Stylesheet& stylesheetTree, 00111 const XalanDOMChar* name, 00112 const AttributeListType& atts); 00113 00114 /** 00115 * Construct an object corresponding to a literal result element 00116 * 00117 * @param constructionContext context for construction of object 00118 * @param stylesheetTree stylesheet containing element 00119 * @param name name of element 00120 * @param atts list of attributes for element 00121 * @param lineNumber line number in document 00122 * @param columnNumber column number in document 00123 * @param xslToken The xsl token value for this class 00124 */ 00125 ElemLiteralResult( 00126 StylesheetConstructionContext& constructionContext, 00127 Stylesheet& stylesheetTree, 00128 const XalanDOMChar* name, 00129 const AttributeListType& atts, 00130 XalanFileLoc lineNumber, 00131 XalanFileLoc columnNumber, 00132 int xslToken); 00133 00134 virtual void 00135 namespacesPostConstruction( 00136 StylesheetConstructionContext& constructionContext, 00137 const NamespacesHandler& theParentHandler, 00138 NamespacesHandler& theHandler); 00139 00140 private: 00141 00142 // not implemented 00143 ElemLiteralResult(const ElemLiteralResult &); 00144 00145 ElemLiteralResult& 00146 operator=(const ElemLiteralResult&); 00147 00148 00149 /** 00150 * The name of the literal result element. 00151 */ 00152 const XalanDOMString& m_elementName; 00153 00154 /** 00155 * A vector to keep track of the attribute elements. 00156 */ 00157 const AVT** m_avts; 00158 00159 /** 00160 * The size of m_avts, once the stylesheet is compiled... 00161 */ 00162 XalanSize_t m_avtsCount; 00163 }; 00164 00165 00166 00167 XALAN_CPP_NAMESPACE_END 00168 00169 00170 00171 #endif // XALAN_ELEMLITERALRESULT_HEADER_GUARD
Doxygen and GraphViz are used to generate this API documentation from the Xalan-C header files.
Xalan-C++ XSLT Processor Version 1.11 |
|