4.2. Simple DAO Session Handler (Default) Example Configuration

This implementation uses ADO.NET to provide a connection and transaction via the ADO.NET API.

Example 4.1. Example Simple DAO Session Handler configuration

<context id="SimpleDao" default="true">
  <properties resource="database.config"/>

  <database>
    <!-- Optional ( default ) -->
    <provider name="sqlServer1.1"/>
    <dataSource name="iBatisNet" 
                connectionString="data source=${datasource};database=${database};
                user id=${userid};password=${password}"/>
  </database>

  <!-- Element daoSessionHandler (ADONET) is Optional ( default ) -->

  <daoFactory>
    <dao interface="IBatisNet.Test.Dao.Interfaces.IAccountDao, IBatisNet.Test"
         implementation="IBatisNet.Test.Dao.Implementations.Ado.AccountDao, IBatisNet.Test"/>
  </daoFactory>
</context>