Oracle9i Warehouse Builder User's Guide Release 2 (v9.0.2) Part Number A95949-01 |
|
The Warehouse Builder Batch Services interface is called WBBatchInvokeAPI.java
. All third parties should use this Batch Service API to integrate with and invoke essential services that are provided by Warehouse Builder. The services supported through Batch Services are metadata import, validation, generation, and deployment.
WBBatchInvokeAPI
can be accessed by importing in a Java class by using the following:
The Batch Service interface provides the following types of methods to enable third party developers to access Oracle9i Warehouse Builder through batch interaction:
Repository methods include:
To establish a connection with the metadata repository, use the following method. You must enter five parameters: username, password, host name, port number, and SID. This method will cause a WBConnectionFailureException and WBException if the method fails to establish a connection with the repository.
public void openConnection(
String username, String password, String host, String port, String sid) throws WBConnectionFailureException, WBException;
The following methods are available for closing repository connections:
public void closeConnection() throws WBException, SQLException;
public void commitCloseConnection() throws WBException, SQLException;
The following methods are available for manipulating projects:
public String[] getProjects() throws WBException;
public void setCurrentProject(String projectName) throws WBException;
The following methods are available for manipulating modules:
public String[] getModules() throws WBException;
public void setCurrentModule(String appName) throws WBException;
An element such as a dimension or a table must be validated. This can be done using the validate method. Provide an application name, the element name, and type of the element. The typename
can be any of the following: TABLE, VIEW, MATERIALIZEDVIEW, DIMENSION, FACT, SEQUENCE, MAPPING.
public boolean validate(
String appName, String elementname, String typename) throws WBException;
After the validation has been performed, you can get the validation results in an array of strings.
public String[] getValidationResults(
String appName, String element, String typeName) throws WBException;
Display the validation results in the console by using the following method:
public void displayValidationResults(
String appName, String element, String type) throws WBException;
To generate an element, use the following generate method. The typename
can be any of the following: TABLE, VIEW, MATERIALIZEDVIEW, DIMENSION, FACT, SEQUENCE, MAPPING.
public void generate(
String appName, String elementname, String typename) throws WBException;
The following methods allow you to deploy your previously generated scripts to either a file system or database. The typename
can be any of the following: TABLE, VIEW, MATERIALIZEDVIEW, DIMENSION, FACT, SEQUENCE, MAPPING.
public void deployInFileSystem(
String appName, String elementname, String typeName, String deployDir) throws WBException;
public void deployInDatabase(
String appName, String elementname, String typename, String user, String passwd, String host, String port, String sid) throws WBException, Exception;
Deployment Results can extracted by using the following:
public String[] getDeploymentResults() throws WBException;
The following method allows importing of MDL exported data as an input stream. The log file parameter must include the full path name. The Mode denotes the mode of importing (Create, Update). The usePhyiscalName parameter ensures that the user uses a physical name while importing.
public void importMetaData(
InputStream importFileStream, String logFile, String mode, boolean usePhysicalNames) throws WBException, IOException;
The following method allows the import of Metadata using an MDL exported file without using the character set. The default character set is used.
public void importMetaData(
String m_import_file, String m_log_file, String m_mode, boolean m_usePhysicalNames) throws WBException;
The following method allows the import of metadata using an MDL exported file. A valid character set string would look like WE8MSWIN1252.
public void importMetaData(
String m_import_file, String m_log_file, String m_mode, boolean m_usePhysicalNames, String characterSet) throws WBException;
The following method exports metadata using mandatory parameters.
public boolean exportMetaData( String projectName, String appName, String elementName, String typeName, String exportFileName, String logFileName, String characterSet, String fieldSeparator ) throws WBException, Exception
The following method exports metadata using mandatory parameters. It also allows the user to specify the use of the physicalName. The physicalName argument can be true or false. The default value is true.
public boolean exportMetaData( String projectName, String appName, String elementName, String typeName, String exportFileName, String logFileName, String characterSet, String fieldSeparator, String physicalName ) throws WBException, Exception
The following method exports metadata using mandatory parameters and optional parameters.
public boolean exportMetaData( String projectName, String appName, String elementName, String typeName, String exportFileName, String logFileName, String characterSet, String fieldSeparator, String physicalName, String configParameter ) throws WBException, Exception
|
![]() Copyright © 1996, 2002 Oracle Corporation. All Rights Reserved. |
|