uk.ac.ic.doc.automed.ssd
Class SSDFormat

java.lang.Object
  extended by uk.ac.ic.doc.automed.ssd.SSDFormat

public class SSDFormat
extends java.lang.Object

The SSDFormat class represents a format of a particular semistructured datasource as a set of SSDPatterns.

Author:
Sasivimol Kittivoravitkul (sk297@doc.ic.ac.uk)

Constructor Summary
SSDFormat(java.lang.String name)
           
 
Method Summary
static SSDFormat createSSDFormat(java.lang.String name, Schema s)
          Create a SSDFormat
 SSDPattern createSSDPattern(Pattern p)
           
static boolean exists(int sid)
          Returns true if the format for the specified schema identifier exists
static boolean exists(java.lang.String ssdfName)
          Returns true if the format for the specified ssdformat exists
 int getGroupNoByOBID(int obid)
           
 java.lang.String getName()
           
 int getOBIDBySPID(int spid)
           
 java.util.Vector getPattern()
           
 Schema getSchema()
           
 int getSFID()
           
static int getSFID(java.lang.String name)
           
 int getSPIDByOBID(int obid)
           
static SSDFormat getSSDFormat(int id)
           
static SSDFormat getSSDFormat(java.lang.String name)
           
static SSDFormat getSSDFormatBySchema(Schema s)
           
static java.lang.String getSSDFormatName(int id)
           
 SSDPattern getSSDPatternBySPID(int spid)
           
 int[] getSSDPatternIDs()
           
static void retract(java.lang.String name)
           
 void setPatternToSchemaObject(SSDPattern sp, SchemaObject sobj, int gno)
           
 void setSchema(Schema s)
           
 void setSSDPattern(SSDPattern p)
           
 void updateSSDPatterns()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SSDFormat

public SSDFormat(java.lang.String name)
Method Detail

exists

public static boolean exists(java.lang.String ssdfName)
Returns true if the format for the specified ssdformat exists

Parameters:
ssdformatName - A name of the semistructured data source format

exists

public static boolean exists(int sid)
Returns true if the format for the specified schema identifier exists

Parameters:
sid - An identifier of the schema

updateSSDPatterns

public void updateSSDPatterns()
                       throws SSMDRException,
                              java.sql.SQLException,
                              java.io.IOException,
                              DSRException
Throws:
SSMDRException
java.sql.SQLException
java.io.IOException
DSRException

createSSDFormat

public static SSDFormat createSSDFormat(java.lang.String name,
                                        Schema s)
                                 throws SSMDRException,
                                        java.sql.SQLException,
                                        java.io.IOException,
                                        DSRException
Create a SSDFormat

Parameters:
name - A name of the ssdformat
s - A schema of a datasource that is represented by the ssdformat
Throws:
SSMDRException
java.sql.SQLException
java.io.IOException
DSRException

createSSDPattern

public SSDPattern createSSDPattern(Pattern p)

setSSDPattern

public void setSSDPattern(SSDPattern p)

setSchema

public void setSchema(Schema s)
               throws SSMDRException,
                      java.sql.SQLException,
                      DSRException,
                      java.io.IOException
Throws:
SSMDRException
java.sql.SQLException
DSRException
java.io.IOException

setPatternToSchemaObject

public void setPatternToSchemaObject(SSDPattern sp,
                                     SchemaObject sobj,
                                     int gno)
                              throws SSMDRException,
                                     java.sql.SQLException,
                                     DSRException,
                                     java.io.IOException
Throws:
SSMDRException
java.sql.SQLException
DSRException
java.io.IOException

retract

public static void retract(java.lang.String name)

getSFID

public static int getSFID(java.lang.String name)

getSSDFormatBySchema

public static SSDFormat getSSDFormatBySchema(Schema s)

getSSDFormatName

public static java.lang.String getSSDFormatName(int id)

getSSDPatternIDs

public int[] getSSDPatternIDs()
                       throws SSMDRException,
                              java.sql.SQLException,
                              DSRException,
                              java.io.IOException
Throws:
SSMDRException
java.sql.SQLException
DSRException
java.io.IOException

getSSDFormat

public static SSDFormat getSSDFormat(java.lang.String name)

getSSDFormat

public static SSDFormat getSSDFormat(int id)

getSSDPatternBySPID

public SSDPattern getSSDPatternBySPID(int spid)

getSPIDByOBID

public int getSPIDByOBID(int obid)
                  throws SSMDRException,
                         java.sql.SQLException,
                         DSRException,
                         java.io.IOException
Throws:
SSMDRException
java.sql.SQLException
DSRException
java.io.IOException

getOBIDBySPID

public int getOBIDBySPID(int spid)
                  throws SSMDRException,
                         java.sql.SQLException,
                         DSRException,
                         java.io.IOException
Throws:
SSMDRException
java.sql.SQLException
DSRException
java.io.IOException

getGroupNoByOBID

public int getGroupNoByOBID(int obid)
                     throws SSMDRException,
                            java.sql.SQLException,
                            DSRException,
                            java.io.IOException
Throws:
SSMDRException
java.sql.SQLException
DSRException
java.io.IOException

getName

public java.lang.String getName()

getSFID

public int getSFID()

getSchema

public Schema getSchema()

getPattern

public java.util.Vector getPattern()