这个模块是为了让本平台支持ORM而设计的。这涉及到更高一级别的代码编写了。前期没有什么编程基础的用户可以先跳过,这部分对平台的使用影响不大,先作一个简单的了解。如果有等后期有需要了,具体的开发教程部分我们会作详细讲解。
生成的类类型分为两种:CustomObject和DataRowObject,第一种CustomObject就是常规的DTO(Data Transfer Object),而DataRowObject则是针对ORM(Object Relational Mapping)。生成的四种结果示例如下:
C#【CustomObject】
using System;
using System.ComponentModel;
namespace sanMuSoft.CS.Framework
{
public class SysAutoIDRecycle
{
[Browsable(true), ReadOnly(false), DisplayName("_Locked"), Category("行为"), Description("")]
public Boolean _Locked { get; set; }
[Browsable(true), ReadOnly(false), DisplayName("_SortKey"), Category("行为"), Description("")]
public Decimal _SortKey { get; set; }
[Browsable(true), ReadOnly(false), DisplayName("_Identify"), Category("行为"), Description("")]
public Int64 _Identify { get; set; }
/// <summary>
///备注类型,RuleID,GUID
/// </summary>
/// <value></value>
/// <returns></returns>
/// <remarks></remarks>
[Browsable(true), ReadOnly(false), DisplayName("RuleID"), Category("行为"), Description("备注类型,RuleID,GUID")]
public String RuleID { get; set; }
/// <summary>
///备注类型,回收ID
/// </summary>
/// <value></value>
/// <returns></returns>
/// <remarks></remarks>
[Browsable(true), ReadOnly(false), DisplayName("回收ID"), Category("行为"), Description("备注类型,回收ID")]
public String RecycleID { get; set; }
/// <summary>
///备注类型,创建者
/// </summary>
/// <value></value>
/// <returns></returns>
/// <remarks></remarks>
[Browsable(true), ReadOnly(false), DisplayName("创建者"), Category("行为"), Description("备注类型,创建者")]
public String CreateUser { get; set; }
/// <summary>
///日期时间类型,创建时间
/// </summary>
/// <value></value>
/// <returns></returns>
/// <remarks></remarks>
[Browsable(true), ReadOnly(false), DisplayName("创建时间"), Category("行为"), Description("日期时间类型,创建时间")]
public DateTime CreateTime { get; set; }
/// <summary>
///备注类型,回收类型
/// </summary>
/// <value></value>
/// <returns></returns>
/// <remarks></remarks>
[Browsable(true), ReadOnly(false), DisplayName("回收类型"), Category("行为"), Description("备注类型,回收类型")]
public String RecycleType { get; set; }
}
}
C#【DataRowObject】 |
using System; using System.ComponentModel; using System.Data; using sanMuSoft.Data; namespace sanMuSoft.CS.Framework { public class SysAutoIDRecycle:RowDataObjectBase { [Browsable(true), ReadOnly(false), DisplayName("_Locked"), Category("行为"), Description("")] public Boolean _Locked { get { return RowData[nameof(this._Locked)].CType<Boolean>(); } set { RowData[nameof(this._Locked)] = value; } } [Browsable(true), ReadOnly(false), DisplayName("_SortKey"), Category("行为"), Description("")] public Decimal _SortKey { get { return RowData[nameof(this._SortKey)].CType<Decimal>(); } set { RowData[nameof(this._SortKey)] = value; } } [Browsable(true), ReadOnly(false), DisplayName("_Identify"), Category("行为"), Description("")] public Int64 _Identify { get { return RowData[nameof(this._Identify)].CType<Int64>(); } set { RowData[nameof(this._Identify)] = value; } } /// <summary> ///备注类型,RuleID,GUID /// </summary> /// <value></value> /// <returns></returns> /// <remarks></remarks> [Browsable(true), ReadOnly(false), DisplayName("RuleID"), Category("行为"), Description("备注类型,RuleID,GUID")] public String RuleID { get { return RowData[nameof(this.RuleID)].CType<String>(); } set { RowData[nameof(this.RuleID)] = value; } } /// <summary> ///备注类型,回收ID /// </summary> /// <value></value> /// <returns></returns> /// <remarks></remarks> [Browsable(true), ReadOnly(false), DisplayName("回收ID"), Category("行为"), Description("备注类型,回收ID")] public String RecycleID { get { return RowData[nameof(this.RecycleID)].CType<String>(); } set { RowData[nameof(this.RecycleID)] = value; } } /// <summary> ///备注类型,创建者 /// </summary> /// <value></value> /// <returns></returns> /// <remarks></remarks> [Browsable(true), ReadOnly(false), DisplayName("创建者"), Category("行为"), Description("备注类型,创建者")] public String CreateUser { get { return RowData[nameof(this.CreateUser)].CType<String>(); } set { RowData[nameof(this.CreateUser)] = value; } } /// <summary> ///日期时间类型,创建时间 /// </summary> /// <value></value> /// <returns></returns> /// <remarks></remarks> [Browsable(true), ReadOnly(false), DisplayName("创建时间"), Category("行为"), Description("日期时间类型,创建时间")] public DateTime CreateTime { get { return RowData[nameof(this.CreateTime)].CType<DateTime>(); } set { RowData[nameof(this.CreateTime)] = value; } } /// <summary> ///备注类型,回收类型 /// </summary> /// <value></value> /// <returns></returns> /// <remarks></remarks> [Browsable(true), ReadOnly(false), DisplayName("回收类型"), Category("行为"), Description("备注类型,回收类型")] public String RecycleType { |