org.apache.jena.riot.other
Class GLib

java.lang.Object
  extended by org.apache.jena.riot.other.GLib

public class GLib
extends Object

A collection of Graph/Triple/Node related functions


Field Summary
static Transform<Quad,Node> projectQuadGraphName
          Transform quad to graphname
static Transform<Quad,Node> projectQuadObject
          Transform quad to object
static Transform<Quad,Node> projectQuadPredicate
          Transform quad to predicate
static Transform<Quad,Node> projectQuadSubject
          Transform quad to subject
static Transform<Triple,Node> projectTripleObject
          Transform triple to object
static Transform<Triple,Node> projectTriplePredicate
          Transform triple to predicate
static Transform<Triple,Node> projectTripleSubject
          Transform triple to subject
 
Constructor Summary
GLib()
           
 
Method Summary
static Iterator<Node> listObjects(Graph graph)
          List the objects in a graph (no duplicates)
static Iterator<Node> listPredicates(Graph graph)
          List the predicates in a graph (no duplicates)
static Iterator<Node> listSubjects(Graph graph)
          List the subjects in a graph (no duplicates)
static Node nullAsAny(Node x)
          Convert null to Node.ANY
static Node nullAsDft(Node x, Node dft)
          Convert null to some default Node
static Iterator<Node> quad2graphName(Iterator<Quad> iter)
          Project quad to graphname
static Iterator<Node> quad2object(Iterator<Quad> iter)
          Project quad to object
static Iterator<Node> quad2predicate(Iterator<Quad> iter)
          Project quad to predicate
static Iterator<Node> quad2subject(Iterator<Quad> iter)
          Project quad to graphname
static Iter<Triple> quads2triples(Iterator<Quad> iter)
          Project quads to triples
static Iterator<Node> triple2object(Iterator<Triple> iter)
          Project triple to object
static Iterator<Node> triple2predicate(Iterator<Triple> iter)
          Project triple to predicate
static Iterator<Node> triple2subject(Iterator<Triple> iter)
          Project triple to subject
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

projectQuadGraphName

public static Transform<Quad,Node> projectQuadGraphName
Transform quad to graphname


projectQuadSubject

public static Transform<Quad,Node> projectQuadSubject
Transform quad to subject


projectQuadPredicate

public static Transform<Quad,Node> projectQuadPredicate
Transform quad to predicate


projectQuadObject

public static Transform<Quad,Node> projectQuadObject
Transform quad to object


projectTripleSubject

public static Transform<Triple,Node> projectTripleSubject
Transform triple to subject


projectTriplePredicate

public static Transform<Triple,Node> projectTriplePredicate
Transform triple to predicate


projectTripleObject

public static Transform<Triple,Node> projectTripleObject
Transform triple to object

Constructor Detail

GLib

public GLib()
Method Detail

nullAsAny

public static Node nullAsAny(Node x)
Convert null to Node.ANY


nullAsDft

public static Node nullAsDft(Node x,
                             Node dft)
Convert null to some default Node


listSubjects

public static Iterator<Node> listSubjects(Graph graph)
List the subjects in a graph (no duplicates)


listPredicates

public static Iterator<Node> listPredicates(Graph graph)
List the predicates in a graph (no duplicates)


listObjects

public static Iterator<Node> listObjects(Graph graph)
List the objects in a graph (no duplicates)


quads2triples

public static Iter<Triple> quads2triples(Iterator<Quad> iter)
Project quads to triples


quad2graphName

public static Iterator<Node> quad2graphName(Iterator<Quad> iter)
Project quad to graphname


quad2subject

public static Iterator<Node> quad2subject(Iterator<Quad> iter)
Project quad to graphname


quad2predicate

public static Iterator<Node> quad2predicate(Iterator<Quad> iter)
Project quad to predicate


quad2object

public static Iterator<Node> quad2object(Iterator<Quad> iter)
Project quad to object


triple2subject

public static Iterator<Node> triple2subject(Iterator<Triple> iter)
Project triple to subject


triple2predicate

public static Iterator<Node> triple2predicate(Iterator<Triple> iter)
Project triple to predicate


triple2object

public static Iterator<Node> triple2object(Iterator<Triple> iter)
Project triple to object



Licenced under the Apache License, Version 2.0