it.eng.spagobi.importexport
Class ExportUtilities

java.lang.Object
  extended by it.eng.spagobi.importexport.ExportUtilities

public class ExportUtilities
extends java.lang.Object

Imlements utilities for export purposes


Constructor Summary
ExportUtilities()
           
 
Method Summary
static void copyMetadataScript(java.lang.String pathDBFolder)
          Copy the metadata script of the exported database into the export folder
static void copyMetadataScriptProperties(java.lang.String pathDBFolder)
          Copy the properties file of the exported database into the export folder
static java.sql.Connection getConnectionExportDB(java.lang.String pathDBFolder)
          Creates a sql connection for the exported database
static it.eng.spago.dbaccess.sql.DataConnection getDataConnection(java.sql.Connection con)
          Creates a Spago DataConnection object starting from a connection to the export database
static org.hibernate.SessionFactory getHibSessionExportDB(java.lang.String pathDBFolder)
          Creates an Hibernate session factory for the export database
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ExportUtilities

public ExportUtilities()
Method Detail

copyMetadataScript

public static void copyMetadataScript(java.lang.String pathDBFolder)
                               throws it.eng.spago.error.EMFUserError
Copy the metadata script of the exported database into the export folder

Parameters:
pathDBFolder - Path of the export database folder
Throws:
it.eng.spago.error.EMFUserError

copyMetadataScriptProperties

public static void copyMetadataScriptProperties(java.lang.String pathDBFolder)
                                         throws it.eng.spago.error.EMFUserError
Copy the properties file of the exported database into the export folder

Parameters:
pathDBFolder - Path of the export database folder
Throws:
it.eng.spago.error.EMFUserError

getHibSessionExportDB

public static org.hibernate.SessionFactory getHibSessionExportDB(java.lang.String pathDBFolder)
                                                          throws it.eng.spago.error.EMFUserError
Creates an Hibernate session factory for the export database

Parameters:
pathDBFolder - Path of the export database folder
Returns:
The Hibernate Session Factory
Throws:
it.eng.spago.error.EMFUserError

getConnectionExportDB

public static java.sql.Connection getConnectionExportDB(java.lang.String pathDBFolder)
                                                 throws it.eng.spago.error.EMFUserError
Creates a sql connection for the exported database

Parameters:
pathDBFolder - Path of the export database folder
Returns:
Connection to the export database
Throws:
it.eng.spago.error.EMFUserError

getDataConnection

public static it.eng.spago.dbaccess.sql.DataConnection getDataConnection(java.sql.Connection con)
                                                                  throws it.eng.spago.error.EMFInternalError
Creates a Spago DataConnection object starting from a connection to the export database

Parameters:
con - Connection to the export database
Returns:
The Spago DataConnection Object
Throws:
it.eng.spago.error.EMFInternalError