ch.hearc.I04_05s08.Ontology.RDF
Class Instance

java.lang.Object
  extended bych.hearc.I04_05s08.Ontology.RDF.Instance
Direct Known Subclasses:
InstanceOfClass, InstanceOfProperty

public abstract class Instance
extends Object

A RDF instance that represent a RDFS Resource

Author:
Blanc, Yoan
Licence:
MIT
Copyright:
2005 Yoan Blanc, HE-ARC Ing�nierie

Field Summary
private  String name
          The instance's name
private  RdfsResource resource
          The resource
 
Constructor Summary
Instance(Instance instance)
          Build a copy
Instance(RdfsResource resource, String name)
          Build the instance
Instance(String name)
          Build the instance
 
Method Summary
 String getName()
          Get the name of the resource
 RdfsResource getResource()
          Get the resource that is instanciated
 String getShortName()
          Get the short name
 String getShortValue()
          Get the short name
 String getValue()
          Get the value of the resource
 boolean isInstance()
          Get information about if the instance has a resource
 boolean setName(String name)
          Get the name of the resource
 void setResource(RdfsResource resource)
          Set the resource
 void setValue(String value)
          Set the value of the resource
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

resource

private RdfsResource resource
The resource


name

private String name
The instance's name

Constructor Detail

Instance

public Instance(RdfsResource resource,
                String name)
Build the instance

Parameters:
resource - a RDFS Resource
name - the name

Instance

public Instance(String name)
Build the instance

Parameters:
name - the name

Instance

public Instance(Instance instance)
Build a copy

Parameters:
instance - the origin instance
Method Detail

getResource

public RdfsResource getResource()
Get the resource that is instanciated

Returns:
the resource

setResource

public void setResource(RdfsResource resource)
Set the resource

Parameters:
resource - the resource

getName

public String getName()
Get the name of the resource

Returns:
the name of the resource

getShortName

public String getShortName()
Get the short name

Returns:
the short name of the Resource

setName

public boolean setName(String name)
Get the name of the resource

Parameters:
name - the name of the resource

getValue

public String getValue()
Get the value of the resource

Returns:
the value of the resource

getShortValue

public String getShortValue()
Get the short name

Returns:
the short name of the Resource

setValue

public void setValue(String value)
Set the value of the resource

Parameters:
value - the value

isInstance

public boolean isInstance()
Get information about if the instance has a resource

Returns:
if this instance have a parent resource


A project by Blanc, Yoan – supervised by Dr. Ghorbel, Hatem.
2004 © Blanc, Yoan - HE-ARC