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(XNODESETBASE_HEADER_GUARD_1357924680) 00019 #define XNODESETBASE_HEADER_GUARD_1357924680 00020 00021 00022 00023 // Base include file. Must be first. 00024 #include <xalanc/XPath/XPathDefinitions.hpp> 00025 00026 00027 00028 // Base class header file. 00029 #include <xalanc/XPath/XObject.hpp> 00030 00031 00032 00033 #include <xalanc/XPath/NodeRefListBase.hpp> 00034 #include <xalanc/XPath/XNodeSetResultTreeFragProxy.hpp> 00035 00036 00037 00038 XALAN_CPP_NAMESPACE_BEGIN 00039 00040 00041 00042 /** 00043 * Class to hold XPath return types. 00044 */ 00045 class XALAN_XPATH_EXPORT XNodeSetBase : public XObject 00046 { 00047 public: 00048 00049 typedef NodeRefListBase::size_type size_type; 00050 00051 typedef XObject ParentType; 00052 00053 virtual 00054 ~XNodeSetBase(); 00055 00056 // These methods are inherited from XObject ... 00057 00058 00059 virtual const XalanDOMString& 00060 getTypeString() const; 00061 00062 virtual double 00063 num(XPathExecutionContext& executionContext) const; 00064 00065 using ParentType::num; 00066 00067 virtual bool 00068 boolean(XPathExecutionContext& executionContext) const; 00069 00070 virtual const XalanDOMString& 00071 str(XPathExecutionContext& executionContext) const; 00072 00073 virtual const XalanDOMString& 00074 str() const; 00075 00076 virtual void 00077 str( 00078 XPathExecutionContext& executionContext, 00079 FormatterListener& formatterListener, 00080 MemberFunctionPtr function) const; 00081 00082 virtual void 00083 str( 00084 FormatterListener& formatterListener, 00085 MemberFunctionPtr function) const; 00086 00087 virtual void 00088 str( 00089 XPathExecutionContext& executionContext, 00090 XalanDOMString& theBuffer) const; 00091 00092 virtual void 00093 str(XalanDOMString& theBuffer) const; 00094 00095 virtual double 00096 stringLength(XPathExecutionContext& executionContext) const; 00097 00098 virtual const XalanDocumentFragment& 00099 rtree() const; 00100 00101 virtual const NodeRefListBase& 00102 nodeset() const = 0; 00103 00104 virtual void 00105 ProcessXObjectTypeCallback(XObjectTypeCallback& theCallbackObject); 00106 00107 virtual void 00108 ProcessXObjectTypeCallback(XObjectTypeCallback& theCallbackObject) const; 00109 00110 virtual XalanNode* 00111 item(size_type index) const = 0; 00112 00113 virtual size_type 00114 getLength() const = 0; 00115 00116 protected: 00117 00118 /** 00119 * Create an XNodeSetBase 00120 */ 00121 XNodeSetBase(MemoryManager& theMemoryManager); 00122 00123 /** 00124 * Create an XNodeSetBase from another. 00125 * 00126 * @param source object to copy 00127 */ 00128 XNodeSetBase( 00129 const XNodeSetBase& source, 00130 MemoryManager& theMemoryManager); 00131 00132 void 00133 clearCachedValues(); 00134 00135 private: 00136 00137 // Not implemented... 00138 XNodeSetBase(); 00139 XNodeSetBase(const XNodeSetBase&); 00140 XNodeSetBase& 00141 operator=(const XNodeSetBase&); 00142 00143 // Data members... 00144 XNodeSetResultTreeFragProxy m_proxy; 00145 00146 mutable XalanDOMString m_cachedStringValue; 00147 00148 mutable double m_cachedNumberValue; 00149 }; 00150 00151 00152 00153 XALAN_CPP_NAMESPACE_END 00154 00155 00156 00157 #endif // XNODESETBASE_HEADER_GUARD_1357924680
Doxygen and GraphViz are used to generate this API documentation from the Xalan-C header files.
Xalan-C++ XSLT Processor Version 1.11 |
|