Module: util

Utility functions for $rdf
Source:

Methods

(inner) ajarHandleNewTerm()

Loads ontologies of the data we load (this is the callback from the kb to the fetcher). Exports as `AJAR_handleNewTerm`
Source:

(inner) arrayIndexOf()

Exports as `ArrayIndexOf`.
Source:

(inner) callbackify(obj, callbacks)

Adds callback functionality to an object. Callback functions are indexed by a 'hook' string. They return true if they want to be called again.
Parameters:
Name Type Description
obj Object
callbacks Array.<function()>
Source:

(inner) domParser()

Returns a DOM parser based on current runtime environment. Exports as `DOMParserFactory`
Source:

(inner) heavyCompare()

Compares statements (heavy comparison for repeatable canonical ordering)
Source:

(inner) output(o)

Defines a simple debugging function
Parameters:
Name Type Description
o String
Source:

(inner) parseXML()

Returns a DOM from parsex XML.
Source:

(inner) rdfArrayRemove()

Removes all statements equal to x from a Exports as `RDFArrayRemove`
Source:

(inner) stringTemplate()

C++, python style %s -> subs
Source: