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_TraceListenerDefault_HEADER_GUARD) 00019 #define XALAN_TraceListenerDefault_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/TraceListener.hpp> 00030 00031 #include <xalanc/Include/XalanMemoryManagement.hpp> 00032 00033 00034 00035 XALAN_CPP_NAMESPACE_BEGIN 00036 00037 00038 00039 class DOMSupport; 00040 class ElemTemplateElement; 00041 class ExecutionContext; 00042 class NodeRefListBase; 00043 class PrintWriter; 00044 class XPathExecutionContext; 00045 00046 00047 00048 class XALAN_XSLT_EXPORT TraceListenerDefault : public TraceListener 00049 { 00050 public: 00051 00052 TraceListenerDefault( 00053 PrintWriter& thePrintWriter, 00054 MemoryManager& theManager, 00055 bool traceTemplates = false, 00056 bool traceElements = false, 00057 bool traceGeneration = false, 00058 bool traceSelection = false); 00059 00060 TraceListenerDefault( 00061 XPathExecutionContext& theExecutionContext, 00062 PrintWriter& thePrintWriter, 00063 MemoryManager& theManager, 00064 bool traceTemplates = false, 00065 bool traceElements = false, 00066 bool traceGeneration = false, 00067 bool traceSelection = false); 00068 00069 virtual 00070 ~TraceListenerDefault(); 00071 00072 virtual void 00073 trace(const TracerEvent& ev); 00074 00075 virtual void 00076 selected(const SelectionEvent& ev); 00077 00078 virtual void 00079 generated(const GenerateEvent& ev); 00080 00081 bool 00082 getTraceTemplates() const 00083 { 00084 return m_traceTemplates; 00085 } 00086 00087 void 00088 setTraceTemplates(bool b) 00089 { 00090 m_traceTemplates = b; 00091 } 00092 00093 bool 00094 getTraceElement() const 00095 { 00096 return m_traceElements; 00097 } 00098 00099 void 00100 setTraceElements(bool b) 00101 { 00102 m_traceElements = b; 00103 } 00104 00105 bool 00106 getTraceGeneration() const 00107 { 00108 return m_traceGeneration; 00109 } 00110 00111 void 00112 setTraceGeneration(bool b) 00113 { 00114 m_traceGeneration = b; 00115 } 00116 00117 bool 00118 getTraceSelection() const 00119 { 00120 return m_traceSelection; 00121 } 00122 00123 void 00124 setTraceSelection(bool b) 00125 { 00126 m_traceSelection = b; 00127 } 00128 00129 private: 00130 00131 void 00132 processNodeList(const NodeRefListBase& nl); 00133 00134 void 00135 printNodeInfo(const ElemTemplateElement& node); 00136 00137 00138 // Data members... 00139 XPathExecutionContext* m_executionContext; 00140 00141 PrintWriter& m_printWriter; 00142 00143 bool m_traceTemplates; 00144 00145 bool m_traceElements; 00146 00147 bool m_traceGeneration; 00148 00149 bool m_traceSelection; 00150 00151 MemoryManager& m_memoryManager; 00152 }; 00153 00154 00155 00156 XALAN_CPP_NAMESPACE_END 00157 00158 00159 00160 #endif //XALAN_TraceListenerDefault_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 |
|