Search completed in 1.22 seconds.
8 results for "nsirdfcompositedatasource":
RDF in Mozilla FAQ - Archive of obsolete content
Archive › Web Standards › RDF in Mozilla FAQ
teDataSource. This interface has a Flush() method, which will attempt to write the contents of the datasource back to the URL from which they were loaded, using a protocol specific mechanism (e.g., a file: URL just writes the file; an http: URL might do an HTTP-POST). Flush() only writes the datasource if its contents have changed. How do I merge two or more datasources to view them as one? Use nsIRDFCompositeDataSource. This interface is derived from nsIRDFDataSource. An implementation of this interface will typically combine the statements from several datasources together as a collective. Because the nsIRDFCompositeDataSource interface is derived from nsIRDFDataSource, it can be queried and modified just like an individual data source. How do I access "built-in" datasources? A built-in datasource is a local...
... we got this somehow! */; // Get the DOM element for 'my-tree' var tree = document.getElementById('my-tree'); // Add our datasource to it tree.database.AddDataSource(ds); // Force the tree to rebuild *now*. You have to do this "manually"! tree.builder.rebuild(); Any XUL element with a datasources attribute will "get" a database property and a builder property. The database property refers to an nsIRDFCompositeDataSource object, which contains the datasources from which the template is built. The builder property refers to an nsIXULTemplateBuilder object, which is a the "builder" that maintains the state of the template's contents. Note the rdf:null datasource: this is a special datasource that says, "hey, I don't have a datasource for you yet, but I'm going to add one later, so set yourself up for it!" It caus...
A bird's-eye view of the Mozilla framework
Mozilla › Bird s Eye View of the Mozilla Framework
indow by obtaining the link from theContents Panel elements stored in a DOM tree. As a client, getLink() begins by obtaining the XULElement in the DOM tree representing theContents Panel. var tocTree = document.getElementById("help-toc-panel"); The document object is a XULDocument, and tocTree is theContents Panel XULElement. Using the database attribute of the XULElement, getLink() obtains an nsIRDFCompositeDataSource, which presents the individual datasources of the XULElement as a single RDF graph. var tocDS = tocTree.database; NsIRDFCompositeDataSource inherits from nsIRDFDataSource. Help.js declares an nsIRDFService as a compile time constant at the beginning of the file. const RDF = Components.classes["@mozilla.org/rdf/rdf-service;1"].getService(Components.interfaces.nsIRDFService); The Component...
...t the beginning of the file. const RDF = Components.classes["@mozilla.org/rdf/rdf-service;1"].getService(Components.interfaces.nsIRDFService); The Components object is made available to JavaScript via XPConnect; it serves as a bridge connecting JavaScript and XPCOM. getLink() uses the nsIRDFService to obtain an nsIRDFResource for the requested link. var resource = RDF.GetResource(rdfID); nsIRDFCompositeDataSource inherits from nsIRDFDataSource, which supports a GetTarget() method for obtaining the nsIRDFNode for a given resource and property. var link = tocDS.GetTarget(resource, NC_LINK, true); Now that getLink() has the nsIRDFNode for the link, it can call QueryInterface() to check whether the nsIRDFLiteral is supported. link = link.QueryInterface(Components.interfaces.nsIRDFLiteral); If nsIRDFLi...
nsIXULSortService
Mozilla › Tech › XPCOM › Reference › Interface › nsIXULSortService
content/xul/templates/public/nsIXULSortService.idlScriptable A service used to sort the contents of a XUL widget. Inherits from: nsISupports Last changed in Gecko 2.0 (Firefox 4 / Thunderbird 3.3 / SeaMonkey 2.1) Method overview void insertContainerNode(in nsIRDFCompositeDataSource db, in nsRDFSortState sortStatePtr, in nsIContent root, in nsIContent trueParent, in nsIContent container, in nsIContent node, in boolean aNotify); Native code only! Obsolete since Gecko 1.9 void sort(in nsIDOMNode aNode, in AString aSortKey, in AString aSortHints); Constants Constant Value Description SORT_COMPARECASE 0x0001 SORT_INTEGER 0x0100 Methods Native code only!insertContainerNode Obsolete since Gecko 1.9 (Firefox 3)This feature is obsolete. Although it may still work in some browsers, its u...
...nstants Constant Value Description SORT_COMPARECASE 0x0001 SORT_INTEGER 0x0100 Methods Native code only!insertContainerNode Obsolete since Gecko 1.9 (Firefox 3)This feature is obsolete. Although it may still work in some browsers, its use is discouraged since it could be removed at any time. Try to avoid using it. Used internally for insertion sorting. void insertContainerNode( in nsIRDFCompositeDataSource db, in nsRDFSortState sortStatePtr, in nsIContent root, in nsIContent trueParent, in nsIContent container, in nsIContent node, in boolean aNotify ); Parameters db sortStatePtr root trueParent container node aNotify sort() Sort the contents of the widget containing aNode using aSortKey as the comparison key, and aSortHints as how to sort. void sort( in nsIDOMNode aNode, i...
database - Archive of obsolete content
Archive › Mozilla › XUL › Property › database
<< XUL Reference database Type: nsIRDFCompositeDataSource Returns the composite datasource created when all the datasources of an element are combined. Set to null for elements that do not have a datasources attribute. ...
Introduction - Archive of obsolete content
Archive › Mozilla › XUL › Template Guide › Introduction
I of a database file. Only local files are supported, so a file URL should be used. If the datasource type supports it, the template builder can also use multiple datasources which are all combined into a single datasource as if they were all in one datasource to begin with. Only the built-in RDF type supports this mechanism; the XML and SQLite types do not. When multiple datasources are used, an nsIRDFCompositeDataSource is created to hold all of the datasources. You can get this composite datasource in a script by using an element's 'database' property if you want to add or remove datasources from it. When multiple datasources are used, the RDF is combined as if it were one large datasource. That means that a template query can grab data from anywhere in all of the datasources. This combining of datasources is o...
Template Builder Interface - Archive of obsolete content
Archive › Mozilla › XUL › Template Guide › Template Builder Interface
e called by remote code. Changing the Datasource You can modify the datasource that is used for a template by setting the value of the datasources attribute on the root element. Changing this attribute causes the new datasource to be retrieved and the template to be rebuilt. The RDF datasource associated with the template can be retrieved using the element's 'database' property. It implements the nsIRDFCompositeDataSource interface. Since this is a composite datasource, it may contain more than one datasource. These may be listed in the datasources attribute separated by spaces. For example: <vbox datasources="template-guide-photos5.rdf template-guide-streets.rdf"> Sometimes, you will want to calculate the datasource to be used and attach it to the template later. You can do this using the composite datasource's ...
nsIDOMXULElement
Mozilla › Tech › XPCOM › Reference › Interface › nsIDOMXULElement
ean true if the element's collapsed attribute is the string "true", otherwise false. Removes the attribute if you set it to false. contextMenu DOMString Gets/sets the value of the element's contextmenu attribute. controllers nsIControllers Read only. Returns an nsIControllers object that additional controllers may be appended to so as to provide focus-specific actions for commands. database nsIRDFCompositeDataSource Read only. Returns the template builder's database, if it is an RDF template. datasources DOMString Gets/sets the value of the element's datasources attribute. dir DOMString Gets/sets the value of the element's dir attribute. flex DOMString Gets/sets the value of the element's flex attribute. flexGroup DOMString Gets/sets the value of the element's flexgroup attribute. height DOMString ...
nsIXULTemplateBuilder
Mozilla › Tech › XPCOM › Reference › Interface › nsIXULTemplateBuilder
he query processor. May be null if the datasource has not been loaded yet. Set this attribute to use a different datasource and rebuild the template. For an RDF datasource, this will be the same as the database. For XML this will be the nsIDOMNode for the datasource document or node for an inline reference (such as #name). Other query processors may use other types for the datasource. database nsIRDFCompositeDataSource Readonly: The composite datasource that the template builder observes and uses to create content. This is used only for RDF queries and is maintained for backwards compatibility. It will be the same object as the datasource property. For non-RDF queries, it will always be null. rootResult nsIXULTemplateResult Readonly: The virtual result representing the starting reference point, determined by ...