interfaces/RDF_APISPEC.idl Source File

RDF_APISPEC.idl
Go to the documentation of this file.
1 #ifndef INCLUDED_RDF_APISPEC
2 #define INCLUDED_RDF_APISPEC
3 
4 #include "xpcom.idl"
5 #include "CellML_APISPEC.idl"
6 #include "DOM_APISPEC.idl"
7 
12 module rdf_api
13 {
14  interface TripleSet;
15  interface Triple;
16  interface Resource;
17  interface URIReference;
18  interface BlankNode;
19  interface PlainLiteral;
20  interface TypedLiteral;
21  interface Container;
22 
24  {
25  };
26 
30  interface DataSource
32  {
40  URIReference getURIReference(in wstring aURI);
41 
49  BlankNode createBlankNode();
50 
58  PlainLiteral getPlainLiteral(in wstring aForm, in wstring aLanguage);
59 
67  TypedLiteral getTypedLiteral(in wstring aForm, in wstring datatypeURI);
68 
73  TripleSet getAllTriples();
74  };
75 #pragma terminal-interface
76 
81  interface Node
83  {
88  TripleSet getTriplesInto();
89 
96  TripleSet getTriplesIntoByPredicate(in Resource aPredicate);
97  };
98 
102  interface Resource
103  : Node
104  {
111  TripleSet getTriplesOutOfByPredicate(in Resource aPredicate);
112 
120  Triple getTripleOutOfByPredicate(in Resource aPredicate)
121  raises(RDFProcessingError);
122 
130  boolean hasTripleOutOf(in Resource aPredicate, in Node aObject);
131 
140  void createTripleOutOf(in Resource aPredicate, in Node aObject);
141 
148  TripleSet getTriplesOutOfByObject(in Node aObject);
149 
154  TripleSet getTriplesWherePredicate();
155 
160  TripleSet getTriplesWhereSubject();
161 
165  readonly attribute Container correspondingContainer;
166 
179  Container findOrMakeContainer(in Resource aPredicate,
180  in Resource aContainerType);
181 
190  boolean hasTripleOutOfWithPredicateAndObject(in Resource aPredicate, in Node aObject);
191 
200  Triple getTripleOutOfByPredicateAndObject(in Resource aPredicate, in Node aObject)
201  raises(RDFProcessingError);
202  };
203 
207  interface NodeIterator
209  {
213  Node getNextNode();
214  };
215 
219  interface Container
221  {
225  readonly attribute Resource correspondingResource;
226 
232 
236  NodeIterator iterateChildren();
237 
242  void appendChild(in Node aChild);
243 
249  void removeChild(in Node aChild, in boolean aDoRenumbering);
250 
254  void renumberContainer();
255 
268  Container mergeWith(in Container aContainer);
269  };
270 
274  interface BlankNode
275  : Resource
276  {
277  };
278 #pragma terminal-interface
279 
284  interface URIReference
285  : Resource
286  {
290  readonly attribute wstring URI;
291  };
292 #pragma terminal-interface
293 
298  interface Literal
299  : Node
300  {
304  readonly attribute wstring lexicalForm;
305  };
306 
311  interface PlainLiteral
312  : Literal
313  {
317  readonly attribute wstring language;
318  };
319 #pragma terminal-interface;
320 
325  interface TypedLiteral
326  : Literal
327  {
331  readonly attribute wstring datatypeURI;
332  };
333 #pragma terminal-interface;
334 
339  interface Triple
341  {
345  readonly attribute Resource subject;
346 
350  readonly attribute Resource predicate;
351 
355  readonly attribute Node _object;
356 
366  void unassert();
367  };
368 #pragma terminal-interface
369 
372  {
377  Triple getNextTriple();
378  };
379 #pragma terminal-interface
380 
385  interface TripleSet
387  {
391  TripleEnumerator enumerateTriples();
392  };
393 #pragma terminal-interface
394 
395  interface Bootstrap
397  {
401  DataSource createDataSource();
402 
411  void parseIntoDataSource(in DataSource ds, in dom::Element root, in wstring baseURI)
412  raises(RDFProcessingError);
413 
421  dom::Document getDOMForDataSource(in DataSource ds, in wstring baseURI);
422 
430  wstring serialiseDataSource(in DataSource ds, in wstring baseURI);
431  };
432 #pragma terminal-interface
433 
438  {
446  attribute DataSource source;
447  };
448 #pragma terminal-interface
449 };
450 
451 #endif // INCLUDED_RDF_APISPEC
Back to Top