1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* This Source Code Form is subject to the terms of the Mozilla Public
3  * License, v. 2.0. If a copy of the MPL was not distributed with this
4  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
5 
6 #ifndef __TX_XPATH_CONTEXT
7 #define __TX_XPATH_CONTEXT
8 
9 #include "txIXPathContext.h"
10 #include "txNodeSet.h"
11 
12 class txForwardContext : public txIEvalContext {
13  public:
txForwardContext(txIMatchContext * aContext,const txXPathNode & aContextNode,txNodeSet * aContextNodeSet)14   txForwardContext(txIMatchContext* aContext, const txXPathNode& aContextNode,
15                    txNodeSet* aContextNodeSet)
16       : mInner(aContext),
17         mContextNode(aContextNode),
18         mContextSet(aContextNodeSet) {}
19 
20   TX_DECL_EVAL_CONTEXT;
21 
22  private:
23   txIMatchContext* mInner;
24   const txXPathNode& mContextNode;
25   RefPtr<txNodeSet> mContextSet;
26 };
27 
28 #endif  // __TX_XPATH_CONTEXT
29