1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/rdf/base/idl/rdfIDataSource.idl Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,38 @@ 1.4 +/* -*- Mode: IDL; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ 1.5 +/* This Source Code Form is subject to the terms of the Mozilla Public 1.6 + * License, v. 2.0. If a copy of the MPL was not distributed with this 1.7 + * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ 1.8 + 1.9 +#include "nsISupports.idl" 1.10 + 1.11 +interface rdfITripleVisitor; 1.12 + 1.13 +/** 1.14 + * Interface used in RDF to describe data sources. 1.15 + * 1.16 + * @status PLASMA 1.17 + */ 1.18 + 1.19 +[scriptable, uuid(ebce86bd-1568-4a34-a808-9ccf9cde8087)] 1.20 +interface rdfIDataSource : nsISupports 1.21 +{ 1.22 + /** 1.23 + * Visit all the subject resources in the datasource. The order is 1.24 + * intederminate and may change from one invocation to the next. 1.25 + * The subjects will be in the aSubject argument in calls into 1.26 + * aVisitor, aPredicate and aObject will be null. 1.27 + * @note Implementations may throw NS_ERROR_NOT_IMPLEMENTED for 1.28 + * this method, but in this case RDF serializations of this 1.29 + * datasource will not be possible. 1.30 + */ 1.31 + void visitAllSubjects(in rdfITripleVisitor aVisitor); 1.32 + 1.33 + /** 1.34 + * Visit all the triples in the datasource. The order is 1.35 + * intederminate and may change from one invocation to the next. 1.36 + * @note Implementations may throw NS_ERROR_NOT_IMPLEMENTED for 1.37 + * this method, but in this case RDF serializations of this 1.38 + * datasource will not be possible. 1.39 + */ 1.40 + void visitAllTriples(in rdfITripleVisitor aVisitor); 1.41 +};