function RDFGraph() {
    this.resources = [ ];
    this.triples = [ ];
    this.somenum = 0;

    /*
     * Find the index for a resource.
     */

    this.resources.find = function(sURI)
    {
        for (var i = 0, len = this.length; i < len; i++) 
        {
            if (this[i].resource == sURI)
                return i;
        }
        return -1;
    };//find


    /*
     * Add a resource to our list of resources, returning an index.
     * For each resource we keep a list of triples that make use
     * of it.
     */

    this.resources.add = function(sURI) 
    {
        return this.push(
            {
                resource: sURI,
                triples: [ ]
            }
        );
    };//add

    this.resources.len = function() {
        return this.length;
    }
}//RDFStore()
/*
 * This triple store is very basic, and simply holds a list of triples. All resources are
 * placed in a list, and an index is used in the triple list.
 */
This triple store is very basic, and simply holds a list of triples. All resources are
placed in a list, and an index is used in the triple list.
This triple store is very basic and simply holds a list of triples . All resources are placed in a list and an index is used in the triple list .
function RDFGraph() {
    this.resources = [ ];
    this.triples = [ ];
    this.somenum = 0;
    this.resources.find = function(sURI)
    {
        for (var i = 0, len = this.length; i < len; i++) 
        {
            if (this[i].resource == sURI)
                return i;
        }
        return -1;
    };
    this.resources.add = function(sURI) 
    {
        return this.push(
            {
                resource: sURI,
                triples: [ ]
            }
        );
    };
    this.resources.len = function() {
        return this.length;
    }
}
function RDFGraph ( ) { this . resources = [ ] ; this . triples = [ ] ; this . somenum = 0 ; this . resources . find = function ( sURI ) { for ( var i = 0 , len = this . length ; i < len ; i ++ ) { if ( this [ i ] . resource == sURI ) return i ; } return - 1 ; } ; this . resources . add = function ( sURI ) { return this . push ( { resource : sURI , triples : [ ] } ) ; } ; this . resources . len = function ( ) { return this . length ; } }
This triple store is very basic, and simply holds a list of triples.
This triple store is very basic and simply holds a list of triples .
/*
     * Find the index for a resource.
     */ //find /*
     * Add a resource to our list of resources, returning an index.
     * For each resource we keep a list of triples that make use
     * of it.
     */ //add //RDFStore()