corelib.utilities.jdbc
Class DataSourceSet

java.lang.Object
  extended by corelib.utilities.jdbc.DataSourceSet

public class DataSourceSet
extends java.lang.Object

Load all DataSource definitions stored in a XML file.

The XML file must respect this syntaxe.

 <?xml version="1.0" encoding="ISO-8859-1"?>
 <DataSources>
     <DataSource name="MyDataSource" description="Demo web application data source">
         <DriverClassName>com.mysql.jdbc.Driver</DriverClassName>
         <ConnectionURL>jdbc:mysql://localhost:3306/Database</ConnectionURL>
         <Login>root</Login>
         <Password></Password>
     </DataSource>
 </DataSources>
 

Since:
0.4.0
Author:
Alexia Ramaļoli & Dominique Liard
See Also:
DataSource

Constructor Summary
DataSourceSet(java.io.File dataSourceFile)
          Class constructor.
 
Method Summary
 DataSource getDataSource(java.lang.String dataSourceName)
          Returns the specified DataSource.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DataSourceSet

public DataSourceSet(java.io.File dataSourceFile)
              throws java.io.IOException
Class constructor.

Parameters:
dataSourceFile - The file that contains datasource definitions.
Throws:
java.io.IOException - Thrown if this class cannot read the specified file.
Method Detail

getDataSource

public DataSource getDataSource(java.lang.String dataSourceName)
Returns the specified DataSource.

Parameters:
dataSourceName - The name of the desired datasource
Returns:
The specified DataSource if exists, null otherwise.


CAUTION: Ellipse is proposed to you in BETA version to allow evaluation of this framework. Infini Software is released from any responsibility for the use of Ellipse Framework.

Copyright 2012 Infini Software - All Rights Reserved.