content/xul/templates/src/nsXULTemplateResultXML.h

Wed, 31 Dec 2014 06:09:35 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Wed, 31 Dec 2014 06:09:35 +0100
changeset 0
6474c204b198
permissions
-rw-r--r--

Cloned upstream origin tor-browser at tor-browser-31.3.0esr-4.5-1-build1
revision ID fc1c9ff7c1b2defdbc039f12214767608f46423f for hacking purpose.

michael@0 1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
michael@0 2 /* This Source Code Form is subject to the terms of the Mozilla Public
michael@0 3 * License, v. 2.0. If a copy of the MPL was not distributed with this
michael@0 4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
michael@0 5
michael@0 6 #ifndef nsXULTemplateResultXML_h__
michael@0 7 #define nsXULTemplateResultXML_h__
michael@0 8
michael@0 9 #include "nsCOMPtr.h"
michael@0 10 #include "nsIURI.h"
michael@0 11 #include "nsIRDFResource.h"
michael@0 12 #include "nsXULTemplateQueryProcessorXML.h"
michael@0 13 #include "nsIXULTemplateResult.h"
michael@0 14 #include "mozilla/Attributes.h"
michael@0 15
michael@0 16 /**
michael@0 17 * An single result of an query
michael@0 18 */
michael@0 19 class nsXULTemplateResultXML MOZ_FINAL : public nsIXULTemplateResult
michael@0 20 {
michael@0 21 public:
michael@0 22 NS_DECL_ISUPPORTS
michael@0 23
michael@0 24 NS_DECL_NSIXULTEMPLATERESULT
michael@0 25
michael@0 26 nsXULTemplateResultXML(nsXMLQuery* aQuery,
michael@0 27 nsIDOMNode* aNode,
michael@0 28 nsXMLBindingSet* aBindings);
michael@0 29
michael@0 30 ~nsXULTemplateResultXML() {}
michael@0 31
michael@0 32 void GetNode(nsIDOMNode** aNode);
michael@0 33
michael@0 34 protected:
michael@0 35
michael@0 36 // ID used for persisting data. It is constructed using the mNode's
michael@0 37 // base uri plus the node's id to form 'baseuri#id'. If the node has no
michael@0 38 // id, then an id of the form 'row<some number>' is generated. In the
michael@0 39 // latter case, persistence will not work as there won't be a unique id.
michael@0 40 nsAutoString mId;
michael@0 41
michael@0 42 // query that generated the result
michael@0 43 nsCOMPtr<nsXMLQuery> mQuery;
michael@0 44
michael@0 45 // context node in datasource
michael@0 46 nsCOMPtr<nsIDOMNode> mNode;
michael@0 47
michael@0 48 // assignments in query
michael@0 49 nsXMLBindingValues mRequiredValues;
michael@0 50
michael@0 51 // extra assignments made by rules (<binding> tags)
michael@0 52 nsXMLBindingValues mOptionalValues;
michael@0 53 };
michael@0 54
michael@0 55 #endif // nsXULTemplateResultXML_h__

mercurial