Xalan-C++ API Documentation

The Xalan C++ XSLT Processor Version 1.11


FunctionID.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(FUNCTIONID_HEADER_GUARD_1357924680)
19 #define FUNCTIONID_HEADER_GUARD_1357924680
20 
21 
22 
23 // Base header file. Must be first.
25 
26 
27 
31 
32 
33 
34 // Base class header files...
37 
38 
39 
42 
43 
44 
47 
48 
49 
50 XALAN_CPP_NAMESPACE_BEGIN
51 
52 
53 
54 /**
55  * XPath implementation of "id" function.
56  */
58 {
59 public:
60 
62 
63  FunctionID();
64 
65  virtual
66  ~FunctionID();
67 
68  // These methods are inherited from Function ...
69 
70  virtual XObjectPtr
71  execute(
72  XPathExecutionContext& executionContext,
73  XalanNode* context,
74  const XObjectPtr arg1,
75  const Locator* locator) const;
76 
77  using ParentType::execute;
78 
79 #if defined(XALAN_NO_COVARIANT_RETURN_TYPE)
80  virtual Function*
81 #else
82  virtual FunctionID*
83 #endif
84  clone(MemoryManager& theManager) const;
85 
86 protected:
87 
88  virtual const XalanDOMString&
89  getError(XalanDOMString& theResult) const;
90 
91 private:
92 
93  class FunctionIDXObjectTypeCallback : public XObjectTypeCallback
94  {
95  public:
96 
97  FunctionIDXObjectTypeCallback(
98  XPathExecutionContext& theExecutionContext,
99  XalanDOMString& theString);
100 
101  void
102  processCallback(const XObject& theXObject);
103 
104  // These methods are inherited from XObjectTypeCallback ...
105 
106  virtual void
107  Number(
108  const XObject& theXObject,
109  double /* theValue */);
110 
111  virtual void
112  Boolean(
113  const XObject& theXObject,
114  bool /* theValue */);
115 
116  virtual void
117  String(
118  const XObject& theXObject,
119  const XalanDOMString& /* theValue */);
120 
121  virtual void
122  ResultTreeFragment(
123  const XObject& theXObject,
124  const XalanDocumentFragment& /* theValue */);
125 
126  virtual void
127  ResultTreeFragment(
128  const XObject& theXObject,
129  XalanDocumentFragment& /* theValue */);
130 
131  virtual void
132  NodeSet(
133  const XObject& /* theXObject */,
134  const NodeRefListBase& theValue);
135 
136  virtual void
137  Unknown(
138  const XObject& /* theObject */,
139  const XalanDOMString& /* theName */);
140 
141  virtual void
142  Null(const XObject& /* theObject */);
143 
144  private:
145 
146  XalanDOMString& m_resultString;
147 
148  XPathExecutionContext& m_executionContext;
149  };
150 
151  // Not implemented...
152  FunctionID&
153  operator=(const FunctionID&);
154 
155  bool
156  operator==(const FunctionID&) const;
157 };
158 
159 
160 
161 XALAN_CPP_NAMESPACE_END
162 
163 
164 
165 #endif // FUNCTIONID_HEADER_GUARD_1357924680
The purpose of this class is to provide a way to get the "preferred" or closest matching type for XOb...
virtual const XalanDOMString & getError(XalanDOMString &theBuffer) const =0
Get the error message to report when the function is called with the wrong number of arguments...
virtual XObjectPtr execute(XPathExecutionContext &executionContext, XalanNode *context, const XObjectArgVectorType &args, const Locator *locator) const
Execute an XPath function object.
Function ParentType
Definition: FunctionID.hpp:61
Class to hold XObjectPtr return types.
Definition: XObject.hpp:883
Local implementation of NodeRefList.
Class to hold XPath return types.
Definition: XObject.hpp:63
bool operator==(const ElemAttributeSet &theLHS, const ElemAttributeSet &theRHS)
XPath implementation of "id" function.
Definition: FunctionID.hpp:57
virtual Function * clone(MemoryManager &theManager) const =0
Create a copy of the function object.
#define XALAN_XPATH_EXPORT

Interpreting class diagrams

Doxygen and GraphViz are used to generate this API documentation from the Xalan-C header files.

Xalan-C++ XSLT Processor Version 1.11
Copyright © 1999-2012 The Apache Software Foundation.
All Rights Reserved.

Apache Logo