Show / Hide Table of Contents

# Class DbConnectionALExtension

##### Inheritance

System.Object
DbConnectionALExtension

##### Inherited Members

System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()

###### Namespace: Mellivora.Extension

###### Assembly: cs.temp.dll.dll

##### Syntax

    public static class DbConnectionALExtension

### Methods

#### ExecuteIAL<T>(IDbConnection, String, T)

执行AL逻辑的ExecuteNonQuery操作

##### Declaration

    public static int ExecuteIAL<T>(this IDbConnection connection, string key, T instance)

##### Parameters

Type | Name | Description
--- | --- | ---
IDbConnection | connection | 对IDbConnection进行扩展
System.String | key | AL的键
T | instance | command参数化所需的实体类

##### Returns

Type | Description
--- | ---
System.Int32 | 数据库数据变化数量

##### Type Parameters

Name | Description
--- | ---
T | 忽略

#### ExecuteOAL<T>(IDbConnection, String, Object[])

执行AL逻辑的ExecuteNonQuery操作

##### Declaration

    public static int ExecuteOAL<T>(this IDbConnection connection, string key, params object[] instance)

##### Parameters

Type | Name | Description
--- | --- | ---
IDbConnection | connection | 对IDbConnection进行扩展
System.String | key | AL的键
System.Object[] | instance | object参数数组

##### Returns

Type | Description
--- | ---
System.Int32 | 数据库数据变化数量

##### Type Parameters

Name | Description
--- | ---
T | AL实体类类型

#### GetIAL<T, S>(IDbConnection, String, Object)

通过实体类对Command进行填充，通过Vasily的AL逻辑进行数据查询

##### Declaration

    public static IEnumerable<T> GetIAL<T, S>(this IDbConnection connection, string key, object instance)

##### Parameters

Type | Name | Description
--- | --- | ---
IDbConnection | connection | 对IDbConnection进行扩展
System.String | key | AL的键
System.Object | instance | 实体类

##### Returns

Type | Description
--- | ---
System.Collections.Generic.IEnumerable<T> | 数据集合

##### Type Parameters

Name | Description
--- | ---
T | 需要返回数据的类型
S | AL实体类类型

#### GetOAL<T, S>(IDbConnection, String, Object[])

通过object数组对Command进行填充，通过Vasily的AL逻辑进行数据查询

##### Declaration

    public static IEnumerable<T> GetOAL<T, S>(this IDbConnection connection, string key, params object[] instance)

##### Parameters

Type | Name | Description
--- | --- | ---
IDbConnection | connection | 对IDbConnection进行扩展
System.String | key | AL的键
System.Object[] | instance | object参数数组

##### Returns

Type | Description
--- | ---
System.Collections.Generic.IEnumerable<T> | 数据集合

##### Type Parameters

Name | Description
--- | ---
T | 需要返回数据的类型
S | AL实体类类型