18#if !defined(XPATHFACTORY_HEADER_GUARD_1357924680)
19#define XPATHFACTORY_HEADER_GUARD_1357924680
89 bool fInReset =
false) :
90 m_factoryInstance(theFactoryInstance),
98 if (m_fInReset ==
true)
100 return m_factoryInstance.doReturnObject(theXPath,
105 return m_factoryInstance.returnObject(theXPath);
113 const bool m_fInReset;
122 const XPath* theXPath,
123 bool fInReset =
false) = 0;
143 const XPath* theXPath) :
144 m_factory(&theFactory),
157 m_factory = theRHS.m_factory;
158 m_object = theRHS.m_object;
162 theRHS.m_factory = 0;
179 assert(m_object != 0);
203 assert(m_factory != 0);
205 m_factory->returnObject(m_object);
221 const XPath*
const theTemp = m_object;
239 const XPath* m_object;
#define XALAN_CPP_NAMESPACE
#define XALAN_XPATH_EXPORT
virtual bool doReturnObject(const XPath *theXPath, bool fInReset=false)=0
bool returnObject(const XPath *theXPath)
Return an XPath to the factory.
virtual void reset()=0
Reset the instance.
virtual XPath * create()=0
Create an XPath.
Manages the lifetime of an XPath instance.
const XPath * release()
Transfers ownership of XPath to caller.
XPathGuard(XPathGuard &theRHS)
XPathGuard(XPathFactory &theFactory, const XPath *theXPath)
Construct an XPathGuard instance from a factory object and an XPath.
void reset()
Return the referenced object to the factory and set pointers to null.
const XPath * operator->() const
Retrieve the object pointer (must not be null)
const XPath * get() const
Retrieve the object pointer (may be null)
bool operator==(const XalanVector< Type > &theLHS, const XalanVector< Type > &theRHS)
A functor for use with stl algorithms.
DeleteXPathFunctor(XPathFactory &theFactoryInstance, bool fInReset=false)
bool operator()(const XPath *theXPath) const