Update of /cvsroot/springnet/Spring.Net/src/Spring/Spring.Data/Data/Generic
In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv7705/Generic
Modified Files:
AdoTemplate.cs
Log Message:
SPRNET-756 - Add protected method to ErrorCodeExceptionTranslator to allow for a subclass to first attempt exception translation.
Add additional code documentation
Index: AdoTemplate.cs
===================================================================
RCS file: /cvsroot/springnet/Spring.Net/src/Spring/Spring.Data/Data/Generic/AdoTemplate.cs,v
retrieving revision 1.16
retrieving revision 1.17
diff -C2 -d -r1.16 -r1.17
*** AdoTemplate.cs 11 Oct 2007 06:03:20 -0000 1.16
--- AdoTemplate.cs 30 Oct 2007 15:24:44 -0000 1.17
***************
*** 115,118 ****
--- 115,126 ----
}
+ /// <summary>
+ /// Gets or sets a value indicating whether to lazily initialize the
+ /// IAdoExceptionTranslator for this accessor, on first encounter of a
+ /// exception from the data provider. Default is "true"; can be switched to
+ /// "false" for initialization on startup.
+ /// </summary>
+ /// <value><c>true</c> if to lazy initialize the IAdoExceptionTranslator;
+ /// otherwise, <c>false</c>.</value>
public override bool LazyInit
{
***************
*** 121,124 ****
--- 129,137 ----
}
+ /// <summary>
+ /// Gets or sets the exception translator. If no custom translator is provided, a default
+ /// <see cref="ErrorCodeExceptionTranslator"/> is used.
+ /// </summary>
+ /// <value>The exception translator.</value>
public override IAdoExceptionTranslator ExceptionTranslator
{
***************
*** 129,132 ****
--- 142,157 ----
/// <summary>
+ /// Gets or set the System.Type to use to create an instance of IDataReaderWrapper
+ /// for the purpose of having defaults values to use in case of DBNull values read
+ /// from IDataReader.
+ /// </summary>
+ /// <value>The type of the data reader wrapper.</value>
+ public override Type DataReaderWrapperType
+ {
+ get { return classicAdoTemplate.DataReaderWrapperType; }
+ set { classicAdoTemplate.DataReaderWrapperType = value; }
+ }
+
+ /// <summary>
/// Gets the 'Classic' AdoTemplate in Spring.Data
/// </summary>
***************
*** 964,967 ****
--- 989,997 ----
}
+ /// <summary>
+ /// Creates the data reader wrapper for use in AdoTemplate callback methods.
+ /// </summary>
+ /// <param name="readerToWrap">The reader to wrap.</param>
+ /// <returns>The data reader used in AdoTemplate callbacks</returns>
public override IDataReader CreateDataReaderWrapper(IDataReader readerToWrap)
{
***************
*** 969,982 ****
}
- public override Type DataReaderWrapperType
- {
- get { return classicAdoTemplate.DataReaderWrapperType; }
- set { classicAdoTemplate.DataReaderWrapperType = value; }
- }
-
#endregion
#region Parameter Creation Helper Methods
public override IDataParameter[] DeriveParameters(string procedureName, bool includeReturnParameter)
{
--- 999,1012 ----
}
#endregion
#region Parameter Creation Helper Methods
+ /// <summary>
+ /// Derives the parameters of a stored procedure including the return parameter
+ /// </summary>
+ /// <param name="procedureName">Name of the procedure.</param>
+ /// <param name="includeReturnParameter">if set to <c>true</c> to include return parameter.</param>
+ /// <returns>The stored procedure parameters</returns>
public override IDataParameter[] DeriveParameters(string procedureName, bool includeReturnParameter)
{
|