DAL/Session.cs
(开头部分) 3KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
// ******************************************************************
// 文件名: Session.cs
// 主要内容: ISession的实现。
// ******************************************************************
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Reflection;
using Logistics.IDal;
using System.Data.SqlClient;
using System.Data;
namespace Logistics.DAL
{
public class Session : ISessionn
{
#region ISessionn 成员
/// <summary>
/// IDao创造器
/// </summary>
public IDaoBuild daobuild { set; private get; }
/// <summary>
/// 数据事务属性
/// </summary>
public SqlTransaction tran = null;
public System.Data.SqlClient.SqlConnection connection { get; set;}
public int add(object m)
{
string name = m.GetType().Name;
return getIDao(name).add(m) ;
}
public DataTable getModelListByAttribute<T>(string attribute, string value)
{
string name = typeof(T).Name;
return getIDao(name).getModelListByAttribute(attribute,value);
}
public DataTable getModelListByWhere<T>(string where)
{
string name = typeof(T).Name;
return getIDao(name).getModelListByWhere(where);
}
public DataTable getModelList<T>(int top, string where, string orderBy)
{
string name = typeof(T).Name;
return getIDao(name).getModelList(top,where,orderBy);
}
public bool update(object m)
{
string name = m.GetType().Name;
return getIDao(name).update(m);
}
public bool delete(object m)
{
后面还有 65 行代码,购买后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。