Xalan-C++ API Reference 1.12.0
XResultTreeFrag.hpp
Go to the documentation of this file.
1/*
2 * Licensed to the Apache Software Foundation (ASF) under one
3 * or more contributor license agreements. See the NOTICE file
4 * distributed with this work for additional information
5 * regarding copyright ownership. The ASF licenses this file
6 * to you under the Apache License, Version 2.0 (the "License");
7 * you may not use this file except in compliance with the License.
8 * You may obtain a copy of the License at
9 *
10 * http://www.apache.org/licenses/LICENSE-2.0
11 *
12 * Unless required by applicable law or agreed to in writing, software
13 * distributed under the License is distributed on an "AS IS" BASIS,
14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 * See the License for the specific language governing permissions and
16 * limitations under the License.
17 */
18#if !defined(XRESULTTREEFRAG_HEADER_GUARD_1357924680)
19#define XRESULTTREEFRAG_HEADER_GUARD_1357924680
20
21
22
23// Base header file. Must be first.
25
26
27
29
30
31
32// Base class header file.
35
36
37
39
40
41
42namespace XALAN_CPP_NAMESPACE {
43
44
45
46class ResultTreeFrag;
47
48
49
51{
52public:
53
55
56
57 /**
58 * Construct an XResultTreeFrag object from a result tree fragment
59 *
60 * @param value The source result tree fragment.
61 * @param theManager The MemoryManager for this instance.
62 */
65 MemoryManager& theManager);
66
67 /**
68 * Construct an XResultTreeFrag object from another
69 *
70 * @param source source XResultTreeFrag
71 * @param theManager The MemoryManager for this instance.
72 */
74 const XResultTreeFrag& source,
75 MemoryManager& theManager);
76
77 virtual
79
80 MemoryManager&
82 {
83 return m_cachedStringValue.getMemoryManager();
84 }
85
86 void
91
92 // These methods are inherited from XObject ...
93
94 virtual const XalanDOMString&
96
97 virtual double
99
100 virtual double
101 num() const;
102
103 virtual bool
105
106 virtual const XalanDOMString&
108
109 virtual const XalanDOMString&
110 str() const;
111
112 virtual void
116 MemberFunctionPtr function) const;
117
118 virtual void
121 MemberFunctionPtr function) const;
122
123 virtual void
127
128 virtual void
130
131 virtual double
133
134 virtual const XalanDocumentFragment&
135 rtree() const;
136
137 virtual void
139
140 virtual void
142
143 /**
144 * Release the ResultTreeFrag held by the instance.
145 */
148
149 /**
150 * Change the value of an XResultTreeFrag
151 *
152 * @param theValue The new value.
153 */
154 void
156
157protected:
158
159 virtual void
161
162private:
163 //not implemented
166
167 // Data members...
168 XalanDocumentFragment* m_value;
169
170 const XalanDOMString* m_singleTextChildValue;
171
172 StylesheetExecutionContext* m_executionContext;
173
174 mutable XalanDOMString m_cachedStringValue;
175
176 mutable double m_cachedNumberValue;
177};
178
179
180
181}
182
183
184
185#endif // XRESULTTREEFRAG_HEADER_GUARD_1357924680
#define XALAN_XSLT_EXPORT
#define XALAN_CPP_NAMESPACE
Xalan-C++ namespace, including major and minor version.
A SAX-based formatter interface for the XSL processor.
The purpose of this class is to provide a way to get the "preferred" or closest matching type for XOb...
Class to hold XPath return types.
Definition XObject.hpp:64
virtual void dereferenced()
virtual void ProcessXObjectTypeCallback(XObjectTypeCallback &theCallbackObject)
Process a callback request for preferred type information.
virtual bool boolean(XPathExecutionContext &executionContext) const
Cast result object to a boolean.
virtual const XalanDocumentFragment & rtree() const
Cast result object to a result tree fragment.
void setExecutionContext(StylesheetExecutionContext *theExecutionContext)
virtual void str(FormatterListener &formatterListener, MemberFunctionPtr function) const
Send the string value to a FormatterListener instance.
XResultTreeFrag(XalanDocumentFragment &value, MemoryManager &theManager)
Construct an XResultTreeFrag object from a result tree fragment.
virtual void str(XPathExecutionContext &executionContext, FormatterListener &formatterListener, MemberFunctionPtr function) const
Send the string value to a FormatterListener instance.
virtual double num(XPathExecutionContext &executionContext) const
Cast result object to a number.
virtual void ProcessXObjectTypeCallback(XObjectTypeCallback &theCallbackObject) const
Process a callback request for preferred type information.
virtual double stringLength(XPathExecutionContext &executionContext) const
Get the length of the string value of the instance.
MemoryManager & getMemoryManager() const
virtual double num() const
Cast result object to a number.
virtual void str(XalanDOMString &theBuffer) const
Append the string value directly a string.
virtual const XalanDOMString & str() const
Cast result object to a string.
void set(XalanDocumentFragment &theValue)
Change the value of an XResultTreeFrag.
XalanDocumentFragment * release()
Release the ResultTreeFrag held by the instance.
virtual const XalanDOMString & getTypeString() const
Given a request type, return the equivalent string.
XResultTreeFrag(const XResultTreeFrag &source, MemoryManager &theManager)
Construct an XResultTreeFrag object from another.
virtual void str(XPathExecutionContext &executionContext, XalanDOMString &theBuffer) const
Append the string value directly a string.
virtual const XalanDOMString & str(XPathExecutionContext &executionContext) const
Cast result object to a string.