michael@0: /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ michael@0: /* This Source Code Form is subject to the terms of the Mozilla Public michael@0: * License, v. 2.0. If a copy of the MPL was not distributed with this michael@0: * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ michael@0: michael@0: #ifndef nsInstantiationNode_h__ michael@0: #define nsInstantiationNode_h__ michael@0: michael@0: #include "mozilla/Attributes.h" michael@0: #include "nsRuleNetwork.h" michael@0: #include "nsRDFQuery.h" michael@0: michael@0: class nsXULTemplateQueryProcessorRDF; michael@0: michael@0: /** michael@0: * A leaf-level node in the rule network. If any instantiations michael@0: * propagate to this node, then we know we've matched a rule. michael@0: */ michael@0: class nsInstantiationNode : public ReteNode michael@0: { michael@0: public: michael@0: nsInstantiationNode(nsXULTemplateQueryProcessorRDF* aProcessor, michael@0: nsRDFQuery* aRule); michael@0: michael@0: ~nsInstantiationNode(); michael@0: michael@0: // "downward" propagations michael@0: virtual nsresult Propagate(InstantiationSet& aInstantiations, michael@0: bool aIsUpdate, bool& aMatched) MOZ_OVERRIDE; michael@0: michael@0: protected: michael@0: michael@0: nsXULTemplateQueryProcessorRDF* mProcessor; michael@0: nsRDFQuery* mQuery; michael@0: }; michael@0: michael@0: #endif // nsInstantiationNode_h__