org.opensync.engine.server
Interface Adapter

All Known Implementing Classes:
DefaultAdapter

public interface Adapter

The adpter interface is used to convert the data source format to the OpenSync data format


Method Summary
 java.lang.String adaptInputView(java.lang.String xml, View view, Statistic stat, Window win)
          Adapt the the data source format to the OpenSync data format
 java.lang.String adaptOutputView(java.lang.String xml, View view, Statistic stat)
          Adapt the the data OpenSync format to the data source format
 java.util.List getPKs(org.dom4j.Document themes, java.lang.String theme)
           
 java.lang.String getTablesDescriptor()
          Get the tables descriptor
 java.lang.String getThemesDescriptor()
          Get the themes descriptor
 void init()
           
 org.dom4j.Document readThemeDescriptor()
           
 void release()
           
 void releaseWithException()
           
 void setTablesDescriptor(java.lang.String tablesDescriptor)
          Set the tables descriptor
 void setThemesDescriptor(java.lang.String themesDescriptor)
          Set the themes descriptor
 void startReadInputFile(boolean status)
           
 void validate()
           
 

Method Detail

setTablesDescriptor

public void setTablesDescriptor(java.lang.String tablesDescriptor)
Set the tables descriptor

Parameters:
tablesDescriptor - the url of the tables descriptor

getTablesDescriptor

public java.lang.String getTablesDescriptor()
Get the tables descriptor


setThemesDescriptor

public void setThemesDescriptor(java.lang.String themesDescriptor)
Set the themes descriptor

Parameters:
themesDescriptor - the url of the themes descriptor

getThemesDescriptor

public java.lang.String getThemesDescriptor()
Get the themes descriptor


readThemeDescriptor

public org.dom4j.Document readThemeDescriptor()
                                       throws java.io.FileNotFoundException,
                                              org.dom4j.DocumentException,
                                              org.xml.sax.SAXException,
                                              java.net.MalformedURLException
Throws:
java.io.FileNotFoundException
org.dom4j.DocumentException
org.xml.sax.SAXException
java.net.MalformedURLException

getPKs

public java.util.List getPKs(org.dom4j.Document themes,
                             java.lang.String theme)
                      throws org.dom4j.DocumentException,
                             java.io.FileNotFoundException,
                             org.xml.sax.SAXException,
                             java.net.MalformedURLException
Throws:
org.dom4j.DocumentException
java.io.FileNotFoundException
org.xml.sax.SAXException
java.net.MalformedURLException

adaptInputView

public java.lang.String adaptInputView(java.lang.String xml,
                                       View view,
                                       Statistic stat,
                                       Window win)
                                throws java.lang.Exception
Adapt the the data source format to the OpenSync data format

Parameters:
xml - the view in source format
view - the view
Throws:
java.lang.Exception

adaptOutputView

public java.lang.String adaptOutputView(java.lang.String xml,
                                        View view,
                                        Statistic stat)
                                 throws java.lang.Exception
Adapt the the data OpenSync format to the data source format

Parameters:
xml - the view in OpenSync format
view - the view
Throws:
java.lang.Exception

init

public void init()

release

public void release()
             throws java.sql.SQLException
Throws:
OpenSyncException
java.sql.SQLException

releaseWithException

public void releaseWithException()
                          throws java.sql.SQLException
Throws:
OpenSyncException
java.sql.SQLException

validate

public void validate()
              throws OpenSyncException
Throws:
OpenSyncException

startReadInputFile

public void startReadInputFile(boolean status)
Parameters:
status -


Copyright © 2004 sourceforge. All Rights Reserved.