gr.forth.ics.rdfsuite.swkm.model.impl
Class RDF_Literal

java.lang.Object
  extended by gr.forth.ics.rdfsuite.swkm.model.impl.RDF_Literal
All Implemented Interfaces:
IRDF_Literal, java.io.Serializable

public class RDF_Literal
extends java.lang.Object
implements IRDF_Literal, java.io.Serializable

See Also:
Serialized Form

Field Summary
protected static org.apache.log4j.Logger log
           
 
Constructor Summary
RDF_Literal()
           
RDF_Literal(java.lang.String uri)
           
RDF_Literal(java.lang.String language, java.lang.Object value, java.lang.String type)
           
 
Method Summary
 java.lang.String getLanguage()
          This method retrieves the language of the Literal
 java.lang.String getType()
          This method retrieves the type of the literal
 java.lang.Object getValue()
          This method retrieves the value of the Literal which must be further casted to its type
 void setLanguage(java.lang.String language)
          This method sets the language of the Literal
 void setType(java.lang.String type)
          This method defines the type of the Literal
 void setValue(java.lang.Object value)
          This method sets the value of the Literal
 java.lang.String toString()
           
 java.lang.Object toTrigString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

log

protected static final org.apache.log4j.Logger log
Constructor Detail

RDF_Literal

public RDF_Literal(java.lang.String uri)
            throws gr.forth.ics.rdfsuite.services.exceptions.InvalidRDFLIteralException
Parameters:
uri -
Throws:
gr.forth.ics.rdfsuite.services.exceptions.InvalidRDFLIteralException - if the given string does not correspond to a valid literal

RDF_Literal

public RDF_Literal(java.lang.String language,
                   java.lang.Object value,
                   java.lang.String type)

RDF_Literal

public RDF_Literal()
Method Detail

getLanguage

public java.lang.String getLanguage()
Description copied from interface: IRDF_Literal
This method retrieves the language of the Literal

Specified by:
getLanguage in interface IRDF_Literal
Returns:
A String describing the language of the Literal

getType

public java.lang.String getType()
Description copied from interface: IRDF_Literal
This method retrieves the type of the literal

Specified by:
getType in interface IRDF_Literal
Returns:
A String containing the type of the Literal(e.g "int","String" e.t.c)

getValue

public java.lang.Object getValue()
Description copied from interface: IRDF_Literal
This method retrieves the value of the Literal which must be further casted to its type

Specified by:
getValue in interface IRDF_Literal
Returns:
The value of the Literal

setLanguage

public void setLanguage(java.lang.String language)
Description copied from interface: IRDF_Literal
This method sets the language of the Literal

Specified by:
setLanguage in interface IRDF_Literal
Parameters:
language - A String describing the language of the Literal

setType

public void setType(java.lang.String type)
Description copied from interface: IRDF_Literal
This method defines the type of the Literal

Specified by:
setType in interface IRDF_Literal
Parameters:
type - The String that contains the type of the Literal

setValue

public void setValue(java.lang.Object value)
Description copied from interface: IRDF_Literal
This method sets the value of the Literal

Specified by:
setValue in interface IRDF_Literal
Parameters:
value - The value to be set to the literal

toString

public java.lang.String toString()
Specified by:
toString in interface IRDF_Literal
Overrides:
toString in class java.lang.Object

toTrigString

public java.lang.Object toTrigString()