2001-09-25 05:32:19 +04:00
|
|
|
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
2012-05-21 15:12:37 +04:00
|
|
|
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
2001-03-23 10:39:31 +03:00
|
|
|
|
|
|
|
#ifndef nsInstantiationNode_h__
|
|
|
|
#define nsInstantiationNode_h__
|
|
|
|
|
2013-05-30 00:43:41 +04:00
|
|
|
#include "mozilla/Attributes.h"
|
2001-03-23 10:39:31 +03:00
|
|
|
#include "nsRuleNetwork.h"
|
2006-02-13 19:02:08 +03:00
|
|
|
#include "nsRDFQuery.h"
|
|
|
|
|
|
|
|
class nsXULTemplateQueryProcessorRDF;
|
2001-03-23 10:39:31 +03:00
|
|
|
|
|
|
|
/**
|
|
|
|
* A leaf-level node in the rule network. If any instantiations
|
2001-11-07 07:25:41 +03:00
|
|
|
* propagate to this node, then we know we've matched a rule.
|
2001-03-23 10:39:31 +03:00
|
|
|
*/
|
|
|
|
class nsInstantiationNode : public ReteNode
|
|
|
|
{
|
|
|
|
public:
|
2006-02-13 19:02:08 +03:00
|
|
|
nsInstantiationNode(nsXULTemplateQueryProcessorRDF* aProcessor,
|
|
|
|
nsRDFQuery* aRule);
|
2001-03-23 10:39:31 +03:00
|
|
|
|
|
|
|
~nsInstantiationNode();
|
|
|
|
|
2001-12-24 02:23:41 +03:00
|
|
|
// "downward" propagations
|
2006-02-13 19:02:08 +03:00
|
|
|
virtual nsresult Propagate(InstantiationSet& aInstantiations,
|
2015-03-21 19:28:04 +03:00
|
|
|
bool aIsUpdate, bool& aMatched) override;
|
2001-03-23 10:39:31 +03:00
|
|
|
|
|
|
|
protected:
|
|
|
|
|
2006-02-13 19:02:08 +03:00
|
|
|
nsXULTemplateQueryProcessorRDF* mProcessor;
|
|
|
|
nsRDFQuery* mQuery;
|
2001-03-23 10:39:31 +03:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif // nsInstantiationNode_h__
|