com.clarkparsia.pellet.utils
Class TermFactory

java.lang.Object
  extended by com.clarkparsia.pellet.utils.TermFactory

public class TermFactory
extends java.lang.Object

Author:
Evren Sirin

Field Summary
static aterm.ATermAppl BOTTOM
           
static aterm.ATermAppl BOTTOM_DATA_PROPERTY
           
static aterm.ATermAppl BOTTOM_LIT
           
static aterm.ATermAppl BOTTOM_OBJECT_PROPERTY
           
static aterm.ATermAppl TOP
           
static aterm.ATermAppl TOP_DATA_PROPERTY
           
static aterm.ATermAppl TOP_LIT
           
static aterm.ATermAppl TOP_OBJECT_PROPERTY
           
 
Constructor Summary
TermFactory()
           
 
Method Summary
static aterm.ATermAppl all(aterm.ATermAppl r, aterm.ATermAppl c)
          Create an all values restriction.
static aterm.ATermAppl and(aterm.ATermAppl... c)
           
static aterm.ATermAppl and(aterm.ATermAppl c1, aterm.ATermAppl c2)
           
static aterm.ATermAppl bnode(java.lang.String anonID)
          Create a term that corresponds to a bnode (anonymous term).
static aterm.ATermAppl card(aterm.ATermAppl r, int n, aterm.ATermAppl c)
           
static aterm.ATermAppl hasValue(aterm.ATermAppl r, aterm.ATermAppl ind)
           
static aterm.ATermAppl inv(aterm.ATermAppl r)
           
static aterm.ATermAppl length(aterm.ATermAppl facetValue)
           
static aterm.ATermList list(aterm.ATermAppl... args)
          Create a list of terms.
static aterm.ATermAppl literal(boolean value)
          Create a typed literal with xsd:boolean datatype.
static aterm.ATermAppl literal(byte value)
          Create a typed literal with xsd:byte datatype.
static aterm.ATermAppl literal(double value)
          Create a typed literal with xsd:double datatype.
static aterm.ATermAppl literal(float value)
          Create a typed literal with xsd:float datatype.
static aterm.ATermAppl literal(int value)
          Create a typed literal with xsd:integer datatype.
static aterm.ATermAppl literal(long value)
          Create a typed literal with xsd:long datatype.
static aterm.ATermAppl literal(short value)
          Create a typed literal with xsd:short datatype.
static aterm.ATermAppl literal(java.lang.String value)
          Create an untyped plain literal with no language tag.
static aterm.ATermAppl literal(java.lang.String value, aterm.ATermAppl datatype)
          Create a typed literal with given lexical form and datatypes.
static aterm.ATermAppl literal(java.lang.String value, java.lang.String lang)
          Create an untyped plain literal with the given language tag.
static aterm.ATermAppl literal(java.net.URI value)
          Create a typed literal with xsd:anyURI datatype.
static aterm.ATermAppl max(aterm.ATermAppl r, int n, aterm.ATermAppl c)
           
static aterm.ATermAppl maxExclusive(aterm.ATermAppl facetValue)
           
static aterm.ATermAppl maxInclusive(aterm.ATermAppl facetValue)
           
static aterm.ATermAppl maxLength(aterm.ATermAppl facetValue)
           
static aterm.ATermAppl min(aterm.ATermAppl r, int n, aterm.ATermAppl c)
           
static aterm.ATermAppl minExclusive(aterm.ATermAppl facetValue)
           
static aterm.ATermAppl minInclusive(aterm.ATermAppl facetValue)
           
static aterm.ATermAppl minLength(aterm.ATermAppl facetValue)
           
static aterm.ATermAppl not(aterm.ATermAppl c)
          Create a negated term.
static aterm.ATermAppl oneOf(aterm.ATermAppl... terms)
           
static aterm.ATermAppl or(aterm.ATermAppl... c)
           
static aterm.ATermAppl or(aterm.ATermAppl c1, aterm.ATermAppl c2)
           
static aterm.ATermAppl pattern(aterm.ATermAppl facetValue)
           
static aterm.ATermAppl plainLiteral(java.lang.String value, java.lang.String lang)
          Deprecated. Use literal(String, String) instead
static aterm.ATermAppl restrict(aterm.ATermAppl baseDatatype, aterm.ATermAppl... restrictions)
           
static aterm.ATermAppl self(aterm.ATermAppl p)
           
static aterm.ATermAppl some(aterm.ATermAppl r, aterm.ATermAppl c)
           
static aterm.ATermAppl term(java.lang.String name)
          Create a named term.
static aterm.ATermAppl typedLiteral(java.lang.String value, aterm.ATermAppl dt)
          Deprecated. Use literal(String, ATermAppl) instead
static aterm.ATermAppl typedLiteral(java.lang.String value, java.lang.String dt)
          Deprecated. Use literal(String, ATermAppl) instead
static aterm.ATermAppl value(aterm.ATermAppl r)
           
static aterm.ATermAppl var(java.lang.String name)
          Create a variable temr with the given name.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

TOP

public static final aterm.ATermAppl TOP

BOTTOM

public static final aterm.ATermAppl BOTTOM

TOP_LIT

public static final aterm.ATermAppl TOP_LIT

BOTTOM_LIT

public static final aterm.ATermAppl BOTTOM_LIT

TOP_DATA_PROPERTY

public static final aterm.ATermAppl TOP_DATA_PROPERTY

BOTTOM_DATA_PROPERTY

public static final aterm.ATermAppl BOTTOM_DATA_PROPERTY

TOP_OBJECT_PROPERTY

public static final aterm.ATermAppl TOP_OBJECT_PROPERTY

BOTTOM_OBJECT_PROPERTY

public static final aterm.ATermAppl BOTTOM_OBJECT_PROPERTY
Constructor Detail

TermFactory

public TermFactory()
Method Detail

term

public static aterm.ATermAppl term(java.lang.String name)
Create a named term.

Parameters:
name - name of the term
Returns:
an ATermAppl with the given name and no arguments

bnode

public static aterm.ATermAppl bnode(java.lang.String anonID)
Create a term that corresponds to a bnode (anonymous term).

Parameters:
anonID - is of the anonymous terms
Returns:
an ATermAppl with a single argument for anonID

var

public static aterm.ATermAppl var(java.lang.String name)
Create a variable temr with the given name.

Parameters:
name - name of the variable
Returns:
an ATermAppl with a single argument for variable name

list

public static aterm.ATermList list(aterm.ATermAppl... args)
Create a list of terms.

Parameters:
args - elements of thre list
Returns:
an ATermList with given elements in the given order

not

public static aterm.ATermAppl not(aterm.ATermAppl c)
Create a negated term.

Parameters:
c - Term to be negated
Returns:
an ATermAppl in the form not(c)

all

public static aterm.ATermAppl all(aterm.ATermAppl r,
                                  aterm.ATermAppl c)
Create an all values restriction.

Parameters:
r - property term
c - class or datatype term
Returns:
an ATermAppl in the form all(r,c)

some

public static aterm.ATermAppl some(aterm.ATermAppl r,
                                   aterm.ATermAppl c)

min

public static aterm.ATermAppl min(aterm.ATermAppl r,
                                  int n,
                                  aterm.ATermAppl c)

max

public static aterm.ATermAppl max(aterm.ATermAppl r,
                                  int n,
                                  aterm.ATermAppl c)

card

public static aterm.ATermAppl card(aterm.ATermAppl r,
                                   int n,
                                   aterm.ATermAppl c)

inv

public static aterm.ATermAppl inv(aterm.ATermAppl r)

literal

public static aterm.ATermAppl literal(boolean value)
Create a typed literal with xsd:boolean datatype.

Parameters:
value - boolean value
Returns:
an ATermAppl representing the boolean literal

literal

public static aterm.ATermAppl literal(byte value)
Create a typed literal with xsd:byte datatype.

Parameters:
value - byte value
Returns:
an ATermAppl representing the byte literal

literal

public static aterm.ATermAppl literal(short value)
Create a typed literal with xsd:short datatype.

Parameters:
value - short value
Returns:
an ATermAppl representing the short literal

literal

public static aterm.ATermAppl literal(long value)
Create a typed literal with xsd:long datatype.

Parameters:
value - long value
Returns:
an ATermAppl representing the long literal

literal

public static aterm.ATermAppl literal(int value)
Create a typed literal with xsd:integer datatype.

Parameters:
value - integer value
Returns:
an ATermAppl representing the integer literal

literal

public static aterm.ATermAppl literal(float value)
Create a typed literal with xsd:float datatype.

Parameters:
value - float value
Returns:
an ATermAppl representing the float literal

literal

public static aterm.ATermAppl literal(double value)
Create a typed literal with xsd:double datatype.

Parameters:
value - double value
Returns:
an ATermAppl representing the double literal

literal

public static aterm.ATermAppl literal(java.net.URI value)
Create a typed literal with xsd:anyURI datatype.

Parameters:
value - URI value
Returns:
an ATermAppl representing the URI literal

literal

public static aterm.ATermAppl literal(java.lang.String value)
Create an untyped plain literal with no language tag.

Parameters:
value - string value
Returns:
an ATermAppl representing the plain literal

literal

public static aterm.ATermAppl literal(java.lang.String value,
                                      java.lang.String lang)
Create an untyped plain literal with the given language tag.

Parameters:
value - byte value
lang - language identifier
Returns:
an ATermAppl representing the plain literal with language tag

literal

public static aterm.ATermAppl literal(java.lang.String value,
                                      aterm.ATermAppl datatype)
Create a typed literal with given lexical form and datatypes.

Parameters:
value - lexical value of the literal
datatype - type of the literal
Returns:
an ATermAppl representing the typed literal

plainLiteral

@Deprecated
public static aterm.ATermAppl plainLiteral(java.lang.String value,
                                                      java.lang.String lang)
Deprecated. Use literal(String, String) instead


typedLiteral

public static aterm.ATermAppl typedLiteral(java.lang.String value,
                                           aterm.ATermAppl dt)
Deprecated. Use literal(String, ATermAppl) instead


typedLiteral

public static aterm.ATermAppl typedLiteral(java.lang.String value,
                                           java.lang.String dt)
Deprecated. Use literal(String, ATermAppl) instead


value

public static aterm.ATermAppl value(aterm.ATermAppl r)

and

public static aterm.ATermAppl and(aterm.ATermAppl c1,
                                  aterm.ATermAppl c2)

and

public static aterm.ATermAppl and(aterm.ATermAppl... c)

or

public static aterm.ATermAppl or(aterm.ATermAppl c1,
                                 aterm.ATermAppl c2)

or

public static aterm.ATermAppl or(aterm.ATermAppl... c)

hasValue

public static aterm.ATermAppl hasValue(aterm.ATermAppl r,
                                       aterm.ATermAppl ind)

oneOf

public static aterm.ATermAppl oneOf(aterm.ATermAppl... terms)

self

public static aterm.ATermAppl self(aterm.ATermAppl p)

minInclusive

public static aterm.ATermAppl minInclusive(aterm.ATermAppl facetValue)

minExclusive

public static aterm.ATermAppl minExclusive(aterm.ATermAppl facetValue)

maxInclusive

public static aterm.ATermAppl maxInclusive(aterm.ATermAppl facetValue)

maxExclusive

public static aterm.ATermAppl maxExclusive(aterm.ATermAppl facetValue)

minLength

public static aterm.ATermAppl minLength(aterm.ATermAppl facetValue)

maxLength

public static aterm.ATermAppl maxLength(aterm.ATermAppl facetValue)

length

public static aterm.ATermAppl length(aterm.ATermAppl facetValue)

pattern

public static aterm.ATermAppl pattern(aterm.ATermAppl facetValue)

restrict

public static aterm.ATermAppl restrict(aterm.ATermAppl baseDatatype,
                                       aterm.ATermAppl... restrictions)


Copyright © 2004 Evren Sirin. All Rights Reserved.