def __init__(self, next=None): FoafFilter.__init__(self, next) FOAF = rdflib.Namespace("http://xmlns.com/foaf/0.1/") self.select = ("?value") self.where = GraphPattern([("?node", FOAF['maker'], "?manfloro"), ("?manfloro", FOAF['nick'], "?value")])
def __init__(self, next=None): FoafFilter.__init__(self, next) FOAF = rdflib.Namespace("http://xmlns.com/foaf/0.1/") RDFS = rdflib.Namespace("http://www.w3.org/2000/01/rdf-schema#") RDF = rdflib.Namespace("http://www.w3.org/1999/02/22-rdf-syntax-ns#") self.select = ("?sha1", "?uri") self.where = GraphPattern([("?node", RDFS["seeAlso"], "?uri"), ("?node", RDF["type"], FOAF["Person"])]) ## ("?parent", RDF["type"], FOAF["Person"]), ## ("?parent", RDF["knows"], "?node")]) self.optional = GraphPattern([("?node", FOAF["mbox_sha1sum"], "?sha1")])
def __init__(self, next=None): FoafFilter.__init__(self, next) FOAF = rdflib.Namespace("http://xmlns.com/foaf/0.1/") GEO =rdflib.Namespace("http://www.w3.org/2003/01/geo/wgs84_pos#") RDF = rdflib.Namespace("http://www.w3.org/1999/02/22-rdf-syntax-ns#") self.select = ("?geolat", "?geolong") self.where = GraphPattern([("?node", FOAF['maker'], "?manfloro"), ("?manfloro", FOAF['based_near'], "?bn"), ("?bn",GEO["lat"],"?geolat"), ("?bn",GEO["long"],"?geolong")]) self.relaxedWhere = GraphPattern([("?manfloro", RDF['type'], FOAF['Person']), ("?manfloro", FOAF['based_near'], "?bn"), ("?bn",GEO["lat"],"?geolat"), ("?bn",GEO["long"],"?geolong")])