com.hp.hpl.jena.rdf.model
Interface Selector

All Known Implementing Classes:
SimpleSelector

public interface Selector

A Statement selector.

Model includes list and query methods which will return all the statements which are selected by a selector object. This is the interface of such selector objects.

Version:
Release='$Name: $' Revision='$Revision: 1.2 $' Date='$Date: 2003/06/04 15:14:25 $'
Author:
bwm, kers

Method Summary
 RDFNode getObject()
          Answer the only RDFNode object that this Selector will match, or null if it can match more than a single node.
 Property getPredicate()
          Answer the only predicate Property that this Selector will match, or null if it can match more than a single property.
 Resource getSubject()
          Answer the only subject Resource that this Selector will match, or null if it can match more that a single resource.
 boolean isSimple()
          Answer true iff this Selector is completely characterised by its subject, predicate, and object fields.
 boolean test(Statement s)
          Determine whether a Statement should be selected.
 

Method Detail

test

public boolean test(Statement s)
Determine whether a Statement should be selected.

Parameters:
s - The statement to be considered.
Returns:
true if the statement has been selected.

getSubject

public Resource getSubject()
Answer the only subject Resource that this Selector will match, or null if it can match more that a single resource.


getPredicate

public Property getPredicate()
Answer the only predicate Property that this Selector will match, or null if it can match more than a single property.


getObject

public RDFNode getObject()
Answer the only RDFNode object that this Selector will match, or null if it can match more than a single node.


isSimple

public boolean isSimple()
Answer true iff this Selector is completely characterised by its subject, predicate, and object fields.



Copyright © 2001-2003 Hewlett-Packard. All Rights Reserved.