Xalan-C++ API Reference  1.12.0
XTokenNumberAdapter.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(XTOKENNUMBERADAPTER_HEADER_GUARD_1357924680)
19 #define XTOKENNUMBERADAPTER_HEADER_GUARD_1357924680
20 
21 
22 
23 // Base header file. Must be first.
25 
26 
27 
29 
30 
31 
32 // Base class header file.
34 
35 
36 
37 namespace XALAN_CPP_NAMESPACE {
38 
39 
40 
41 class XToken;
42 
43 
44 
46 {
47 public:
48 
49  /**
50  * Create an XTokenNumberAdapter from an XToken.
51  *
52  * @param theXToken The XToken instance to adapt
53  * @param theMemoryManager The MemoryManager instance.
54  */
56  const XToken& theToken,
57  MemoryManager& theMemoryManager);
58 
59  /**
60  * Create an XTokenNumberAdapter from another one.
61  *
62  * @param source The XTokenNumberAdapter instance to copy
63  * @param theMemoryManager The MemoryManager instance.
64  */
66  const XTokenNumberAdapter& source,
67  MemoryManager& theMemoryManager);
68 
69  virtual
71 
72  // These methods are inherited from XObject ...
73 
74  virtual double
75  num(XPathExecutionContext& executionContext) const;
76 
77  virtual double
78  num() const;
79 
80  virtual const XalanDOMString&
81  str(XPathExecutionContext& executionContext) const;
82 
83  virtual const XalanDOMString&
84  str() const;
85 
86  virtual void
87  str(
88  XPathExecutionContext& executionContext,
89  FormatterListener& formatterListener,
90  MemberFunctionPtr function) const;
91 
92  virtual void
93  str(
94  FormatterListener& formatterListener,
95  MemberFunctionPtr function) const;
96 
97  virtual void
98  str(
99  XPathExecutionContext& executionContext,
100  XalanDOMString& theBuffer) const;
101 
102  virtual void
103  str(XalanDOMString& theBuffer) const;
104 
105  virtual double
106  stringLength(XPathExecutionContext& executionContext) const;
107 
108 protected:
109 
110  virtual eObjectType
111  getRealType() const;
112 
113 private:
114 
115  // XToken instance that we're adapting...
116  const XToken& m_value;
117 };
118 
119 
120 
121 }
122 
123 
124 
125 #endif // XTOKENNUMBERADAPTER_HEADER_GUARD_1357924680
XALAN_CPP_NAMESPACE
#define XALAN_CPP_NAMESPACE
Xalan-C++ namespace, including major and minor version.
Definition: XalanVersion.hpp:76
XalanDOMString.hpp
xalanc::XTokenNumberAdapter
Definition: XTokenNumberAdapter.hpp:45
XALAN_XPATH_EXPORT
#define XALAN_XPATH_EXPORT
Definition: XPathDefinitions.hpp:35
xalanc::XObject::eObjectType
eObjectType
Enumeration of possible object types.
Definition: XObject.hpp:74
XNumberBase.hpp
xalanc::XToken
Definition: XToken.hpp:41
xalanc::XNumberBase
Definition: XNumberBase.hpp:41
xalanc::FormatterListener
A SAX-based formatter interface for the XSL processor.
Definition: FormatterListener.hpp:56
xalanc::XPathExecutionContext
Definition: XPathExecutionContext.hpp:82
xalanc::XalanDOMString
Definition: XalanDOMString.hpp:45
XPathDefinitions.hpp