18 #if !defined(STYLESHEETEXECUTIONCONTEXTDEFAULT_HEADER_GUARD_1357924680) 19 #define STYLESHEETEXECUTIONCONTEXTDEFAULT_HEADER_GUARD_1357924680 43 #if !defined(XALAN_RECURSIVE_STYLESHEET_EXECUTION) 57 #if defined(XALAN_AUTO_PTR_REQUIRES_DEFINITION) 75 XALAN_CPP_NAMESPACE_BEGIN
92 #if defined(XALAN_STRICT_ANSI_HEADERS) 121 MemoryManager& theManager,
142 MemoryManager& theManager,
149 MemoryManager& theManager,
166 m_xpathExecutionContextDefault.setXPathEnvSupport(theSupport);
177 m_xpathExecutionContextDefault.setDOMSupport(theDOMSupport);
188 m_xpathExecutionContextDefault.setXObjectFactory(theXObjectFactory);
202 m_xsltProcessor = theProcessor;
208 return m_usePerInstanceDocumentFactory;
214 m_usePerInstanceDocumentFactory = fValue;
224 getCopyTextNodesOnly()
const;
227 pushCopyTextNodesOnly(
bool copyTextNodesOnly);
230 popCopyTextNodesOnly();
232 #if !defined(XALAN_RECURSIVE_STYLESHEET_EXECUTION) 234 pushProcessCurrentAttribute(
bool processAttribute);
237 popProcessCurrentAttribute();
240 pushSkipElementAttributes(
bool skipAttributes);
243 getSkipElementAttributes()
const;
246 popSkipElementAttributes();
249 pushExecuteIf(
bool executeIf);
256 getRootDocument()
const;
265 getCurrentMode()
const;
274 getCurrentTemplate()
const;
280 popCurrentTemplate();
287 const XalanDOMChar* theName,
288 const XalanDOMChar* theNewType,
289 const XalanDOMChar* theNewValue);
305 const XalanDOMChar* value);
332 setIndent(
int indentAmount);
352 #if defined(XALAN_RECURSIVE_STYLESHEET_EXECUTION) 387 #if defined(XALAN_RECURSIVE_STYLESHEET_EXECUTION) 409 #if !defined(XALAN_RECURSIVE_STYLESHEET_EXECUTION) 410 virtual void beginParams();
412 virtual void endParams();
430 getGlobalStackFrameIndex()
const;
433 getCurrentStackFrameIndex()
const;
436 pushCurrentStackFrameIndex(
int currentStackFrameIndex = -1);
439 popCurrentStackFrameIndex();
455 const XalanDOMChar* ch,
461 const XalanDOMChar* ch,
466 comment(
const XalanDOMChar* data);
470 const XalanDOMChar* target,
471 const XalanDOMChar* data);
479 const Locator* locator);
486 bool shouldCloneAttributes,
487 const Locator* locator);
489 #if !defined(XALAN_RECURSIVE_STYLESHEET_EXECUTION) 491 beginCreateXResultTreeFrag(
XalanNode* sourceNode);
494 endCreateXResultTreeFrag();
504 #if defined(XALAN_RECURSIVE_STYLESHEET_EXECUTION) 506 createXResultTreeFrag(
514 const Locator* locator);
519 const Locator* locator);
534 popElementRecursionStack();
540 getEscapeURLs()
const;
543 setEscapeURLs(eEscapeURLs value);
546 getOmitMETATag()
const;
552 createFormatterToXML(
555 bool doIndent =
false,
556 int indent = eDefaultXMLIndentAmount,
565 createFormatterToHTML(
571 bool doIndent =
true,
572 int indent = eDefaultHTMLIndentAmount,
573 bool escapeURLs =
true,
574 bool omitMetaTag =
false);
577 createFormatterToText(
581 #if !defined(XALAN_RECURSIVE_STYLESHEET_EXECUTION) 593 createXalanNumberFormat();
607 create(MemoryManager& theManager);
613 return s_defaultXalanNumberFormatFactory;
628 getTraceListeners()
const;
640 getTraceSelects()
const;
663 const XalanDOMChar* theLHS,
664 const XalanDOMChar* theRHS,
669 const XalanDOMChar* theLHS,
670 const XalanDOMChar* theRHS,
671 const XalanDOMChar* theLocale,
687 const XalanDOMChar* theLHS,
688 const XalanDOMChar* theRHS,
693 const XalanDOMChar* theLHS,
694 const XalanDOMChar* theRHS,
695 const XalanDOMChar* theLocale,
700 const CollationCompareFunctor*
701 installCollationCompareFunctor(CollationCompareFunctor* theFunctor);
703 CollationCompareFunctor*
704 uninstallCollationCompareFunctor();
724 const Locator* locator = 0)
const = 0;
733 const Locator* locator = 0);
742 const Locator* locator = 0);
749 uninstallFormatNumberFunctor();
763 createPrintWriter(FILE* theStream);
787 getCurrentNode()
const;
790 pushCurrentNode(
XalanNode* theCurrentNode);
804 popContextNodeList();
807 getContextNodeList()
const;
810 getContextNodeListLength()
const;
813 getContextNodeListPosition(
const XalanNode& contextNode)
const;
816 elementAvailable(
const XalanQName& theQName)
const;
821 const Locator* locator)
const;
824 functionAvailable(
const XalanQName& theQName)
const;
829 const Locator* locator)
const;
837 const Locator* locator);
841 MemoryManager& theManager,
844 ErrorHandler* theErrorHandler = 0)
const;
847 borrowMutableNodeRefList();
853 createMutableNodeRefList(MemoryManager& theManager)
const;
855 #if !defined(XALAN_RECURSIVE_STYLESHEET_EXECUTION) 857 createUseAttributeSetIndexesOnStack();
860 getUseAttributeSetIndexes();
863 popUseAttributeSetIndexesFromStack();
875 createAndPushMutableNodeRefList();
878 releaseAndPopMutableNodeRefList();
890 getNextNodeToTransform();
893 popNodesToTransformList();
896 getAndPushCachedString();
899 getLastCachedString();
902 getAndPopCachedString();
917 const Locator* locator,
925 const Locator* locator,
931 const Locator* locator = 0);
934 getPrefixResolver()
const;
946 getUnparsedEntityURI(
951 shouldStripSourceNode(
const XalanText& node);
967 const Locator* locator,
982 m_xsltProcessor(xsltProcessor)
999 getSourceTreeFactory(MemoryManager& theManager)
const;
1001 #if defined(XALAN_RECURSIVE_STYLESHEET_EXECUTION) 1005 borrowFormatterToText();
1014 getDecimalFormatSymbols(
const XalanQName& qname);
1016 #if defined(XALAN_RECURSIVE_STYLESHEET_EXECUTION) 1027 ParamsVectorType& params);
1037 isCached(
const XPath* theXPath);
1055 const XPath* theXPath);
1062 cleanUpTransients();
1070 enum { eXPathCacheMax = 50,
1071 eDefaultParamsVectorSize = 10,
1072 eXResultTreeFragAllocatorBlockSize = 10,
1073 eDocumentAllocatorBlockSize = 10,
1074 eDocumentFragmentAllocatorBlockSize = 10,
1075 eDefaultAttributeAllocatorBlockSize = 10,
1076 eDefaultAttributeNSAllocatorBlockSize = 10,
1077 eDefaultCommentAllocatorBlockSize = 10,
1078 eDefaultElementAllocatorBlockSize = 10,
1079 eDefaultElementNSAllocatorBlockSize = 10,
1080 eDefaultPIAllocatorBlockSize = 10,
1081 eDefaultTextAllocatorBlockSize = 20,
1082 eDefaultTextIWSAllocatorBlockSize = 20 };
1084 ElementTemplateElementStackType m_elementRecursionStack;
1088 FormatterListenerVectorType m_formatterListeners;
1090 PrintWriterVectorType m_printWriters;
1092 OutputStreamVectorType m_outputStreams;
1094 CollationCompareFunctor* m_collationCompareFunctor;
1103 ParamsVectorType m_paramsVector;
1105 XPathCacheMapType m_matchPatternCache;
1107 KeyTablesTableType m_keyTables;
1120 CurrentTemplateStackType m_currentTemplateStack;
1134 BooleanStackType m_copyTextNodesOnlyStack;
1135 ModeStackType m_modeStack;
1136 IntStackType m_currentIndexStack;
1138 #if defined(XALAN_RECURSIVE_STYLESHEET_EXECUTION) 1143 FormatterToTextCacheType m_formatterToTextCache;
1145 FormatterToSourceTreeCacheType m_formatterToSourceTreeCache;
1147 NodeSorterCacheType m_nodeSorterCache;
1154 FormatterToTextDOMString(MemoryManager& theManager);
1157 ~FormatterToTextDOMString();
1162 m_printWriter.setString(theString);
1168 FormatterToTextDOMString(
const FormatterToTextDOMString&);
1170 FormatterToTextDOMString&
1171 operator=(
const FormatterToTextDOMString&);
1174 operator==(
const FormatterToTextDOMString&)
const;
1200 class NodesToTransform
1204 m_nodeList(nodeList), m_index(0)
1206 assert(m_nodeList != 0);
1221 if (m_index < m_nodeList->getLength())
1223 return m_nodeList->item(m_index++);
1235 XObjectPtrStackType m_xobjectPtrStack;
1236 MutableNodeRefListStackType m_mutableNodeRefListStack;
1237 NodesToTransformStackType m_nodesToTransformStack;
1238 BooleanStackType m_processCurrentAttributeStack;
1239 BooleanStackType m_executeIfStack;
1240 StringStackType m_stringStack;
1241 FormatterToTextStackType m_formatterToTextStack;
1242 BooleanStackType m_skipElementAttributesStack;
1243 FormatterToSourceTreeStackType m_formatterToSourceTreeStack;
1244 ParamsVectorStackType m_paramsVectorStack;
1245 ElementTemplateElementStackType m_elementInvokerStack;
1246 UseAttributeSetIndexesStackType m_useAttributeSetIndexesStack;
1253 bool m_usePerInstanceDocumentFactory;
1270 XALAN_CPP_NAMESPACE_END
1274 #endif // STYLESHEETEXECUTIONCONTEXTDEFAULT_HEADER_GUARD_1357924680 XObjectFactory & m_xobjectFactory
void setXObjectFactory(XObjectFactory *theXObjectFactory)
Set the XObjectFactory instance.
void startElement(const XalanDOMChar *name, AttributeListType &atts)
Local implementation of MutableNodeRefList.
void charactersRaw(const XalanDOMChar *ch, size_type start, size_type length)
Receive notification of character data.
XalanMap< XalanDOMString, XPathCacheEntry > XPathCacheMapType
XPathCacheReturnFunctor(XSLTEngineImpl &xsltProcessor)
VariablesStack::ParamsVectorType ParamsVectorTypeDecl
void clearTopLevelParams()
Reset the vector of top level parameters.
bool getQuietConflictWarnings() const
Whether to warn about pattern match conflicts.
ParamsVectorTypeDecl ParamsVectorType
<meta name="usage" content="internal"> This is a table of counters, keyed by ElemNumber objects...
virtual void getUniqueNamespaceValue(XalanDOMString &theValue)
Generate a random namespace prefix guaranteed to be unique.
void outputResultTreeFragment(const XObject &theTree, bool outputTextNodesOnly, const Locator *locator)
Given a result tree fragment, walk the tree and output it to the result stream.
static const XalanDOMString & getXalanXSLNameSpaceURL()
Special Xalan namespace for built-in extensions.
virtual int operator()(const XalanDOMChar *theLHS, const XalanDOMChar *theRHS, eCaseOrder theCaseOrder=eDefault) const =0
This acts as the stylesheet root of the stylesheet tree, and holds values that are shared by all styl...
virtual void resolveTopLevelParams(StylesheetExecutionContext &executionContext)
Resolve the params that were pushed by the caller.
void processingInstruction(const XalanDOMChar *target, const XalanDOMChar *data)
Class to hold XObjectPtr return types.
virtual FormatterListener * getFormatterListener() const
Get the current formatter listener.
static XalanNumberFormatFactory & getDefaultXalanNumberFormatFactory()
eOmitMETATag
Enums to determine whether or not run-time omission of the META tag has been set. ...
This is the class for events generated by the XSL processor after it generates a new node in the resu...
XalanVector< const ElemTemplate * > CurrentTemplateStackType
It's the responsibility of the XSLTEngineImpl class, collaborating with the XML parser liaison...
A basic implementation of the class XPathExecutionContext.
void addResultAttribute(AttributeListImpl &attList, const XalanDOMString &aname, const XalanDOMString &value, bool fromCopy=false, const Locator *locator=0)
Add attribute to attribute list, and if it is a namespace, add it to the namespaces stack...
Local implementation of NodeRefList.
void cloneToResultTree(const XalanNode &node, bool cloneTextNodesOnly, const Locator *locator)
Clone a node to the result tree.
XALAN_STD_QUALIFIER pair< const XPath *, ClockType > XPathCacheEntry
void setXPathEnvSupport(XPathEnvSupport *theSupport)
Set the XPathEnvSupport instance.
void pushOutputContext(FormatterListener *theListener)
void flushPending()
Flush the pending element.
void setXSLTProcessor(XSLTEngineImpl *theProcessor)
Set the DOMSupport instance.
void copyNamespaceAttributes(const XalanNode &src)
Copy XMLNS: attributes in if not already in scope.
static MemoryManager & getDummyMemMgr()
bool isElementPending() const
virtual ~FormatNumberFunctor()
XalanVector< XalanOutputStream * > OutputStreamVectorType
collationCompare(const XalanDOMChar *theLHS, XalanDOMString::size_type theLHSLength, const XalanDOMChar *theRHS, XalanDOMString::size_type theRHSLength)
Compare the contents of two character arrays.
FormatterListener::size_type fl_size_type
eEscapeURLs
Enums to determine whether or not run-time escaping of URLs has been set.
XalanVector< const ElemTemplateElement * > ElementTemplateElementStackType
This class defines an interface for classes that resolve namespace prefixes to their URIs...
void replacePendingAttribute(const XalanDOMChar *theName, const XalanDOMChar *theNewType, const XalanDOMChar *theNewValue)
Replace the contents of a pending attribute.
const XalanDOMString * getResultPrefixForNamespace(const XalanDOMString &theNamespace) const
Retrieve the result prefix corresponding to a namespace.
Class to hold XPath return types.
This is the parent class of events generated for tracing the progress of the XSL processor.
bool isPendingResultPrefix(const XalanDOMString &thePrefix) const
Determine whether or not a prefix is in use on the pending element or the pending attributes...
#define XALAN_USES_MEMORY_MANAGER(Type)
void characters(const XalanDOMChar *ch, size_type length)
#define XALAN_XSLT_EXPORT
XalanCollationServices::CollationCompareFunctor CollationCompareFunctor
NodeRefListBase::size_type size_type
const XPath * createMatchPattern(const XalanDOMString &str, const PrefixResolver &resolver)
Create and initialize an xpath and return it.
static const XalanDOMString & getXSLNameSpaceURL()
Retrieve the URI for the current XSL namespace, for example, "http://www.w3.org/1999/XSL/Transform".
void setDOMSupport(DOMSupport *theDOMSupport)
Set the DOMSupport instance.
void setUsePerInstanceDocumentFactory(bool fValue)
const XalanDOMString * getResultNamespaceForPrefix(const XalanDOMString &prefix) const
Retrieve the result namespace corresponding to a prefix.
bool operator==(const ElemAttributeSet &theLHS, const ElemAttributeSet &theRHS)
XalanDOMString::size_type length(const XalanDOMString &theString)
Get the length of a XalanDOMString.
This class takes SAX events (in addition to some extra events that SAX doesn't handle yet) and produc...
bool getUsePerInstanceDocumentFactory() const
XALAN_STD_QUALIFIER pair< const key_type, data_type > value_type
virtual void setFormatterListener(FormatterListener *flistener)
Set the current formatter listener.
Defines a class to keep track of a stack for macro arguments.
This class can sort vectors of nodes according to a select pattern.
This class handles the creation of XObjects and manages their lifetime.
Stylesheet::KeyTablesTableType KeyTablesTableType
Class to represent a qualified name.
void endElement(const XalanDOMChar *name)
XalanVector< FormatterListener * > FormatterListenerVectorType
void comment(const XalanDOMChar *data)
Called when a Comment is to be constructed.
void returnXPath(const XPath *xpath)
Return the xpath created by createXPath() or createMatchPattern().
XalanVector< PrintWriter * > PrintWriterVectorType
virtual void setStylesheetRoot(const StylesheetRoot *theStylesheet)
Set the root stylesheet.
void outputToResultTree(const XObject &value, bool outputTextNodesOnly, const Locator *locator)
Output an object to the result tree by doing the right conversions.