Spring.NET 1.3.0 RC1 for .NET 2.0 API Reference

ErrorCodeExceptionTranslator.Translate Method

Translate the given SystemException into a generic data access exception.

[Visual Basic]
Public Overridable Sub Translate( _
   ByVal task As String, _
   ByVal sql As String, _
   ByVal exception As Exception _
) _
    Implements IAdoExceptionTranslator.Translate
[C#]
public virtual DataAccessException Translate(
   string task,
   string sql,
   Exception exception
);

Parameters

task
A readable string describing the task being attempted.
sql
The SQL query or update that caused the problem. May be null.
exception
The Exception encountered by the ADO.NET implementation.

Return Value

A DataAccessException appropriate for the supplied exception.

Implements

IAdoExceptionTranslator.Translate

See Also

ErrorCodeExceptionTranslator Class | Spring.Data.Support Namespace