📄 dataset1.cs
字号:
internal 读者表DataTable() :
base("读者表") {
this.InitClass();
}
internal 读者表DataTable(DataTable table) :
base(table.TableName) {
if ((table.CaseSensitive != table.DataSet.CaseSensitive)) {
this.CaseSensitive = table.CaseSensitive;
}
if ((table.Locale.ToString() != table.DataSet.Locale.ToString())) {
this.Locale = table.Locale;
}
if ((table.Namespace != table.DataSet.Namespace)) {
this.Namespace = table.Namespace;
}
this.Prefix = table.Prefix;
this.MinimumCapacity = table.MinimumCapacity;
this.DisplayExpression = table.DisplayExpression;
}
[System.ComponentModel.Browsable(false)]
public int Count {
get {
return this.Rows.Count;
}
}
internal DataColumn 读者号Column {
get {
return this.column读者号;
}
}
internal DataColumn 读者姓名Column {
get {
return this.column读者姓名;
}
}
internal DataColumn 读者性别Column {
get {
return this.column读者性别;
}
}
internal DataColumn 读者班级Column {
get {
return this.column读者班级;
}
}
internal DataColumn 借阅数目Column {
get {
return this.column借阅数目;
}
}
public 读者表Row this[int index] {
get {
return ((读者表Row)(this.Rows[index]));
}
}
public event 读者表RowChangeEventHandler 读者表RowChanged;
public event 读者表RowChangeEventHandler 读者表RowChanging;
public event 读者表RowChangeEventHandler 读者表RowDeleted;
public event 读者表RowChangeEventHandler 读者表RowDeleting;
public void Add读者表Row(读者表Row row) {
this.Rows.Add(row);
}
public 读者表Row Add读者表Row(string 读者号, string 读者姓名, string 读者性别, string 读者班级, int 借阅数目) {
读者表Row row读者表Row = ((读者表Row)(this.NewRow()));
row读者表Row.ItemArray = new object[] {
读者号,
读者姓名,
读者性别,
读者班级,
借阅数目};
this.Rows.Add(row读者表Row);
return row读者表Row;
}
public 读者表Row FindBy读者号(string 读者号) {
return ((读者表Row)(this.Rows.Find(new object[] {
读者号})));
}
public System.Collections.IEnumerator GetEnumerator() {
return this.Rows.GetEnumerator();
}
public override DataTable Clone() {
读者表DataTable cln = ((读者表DataTable)(base.Clone()));
cln.InitVars();
return cln;
}
protected override DataTable CreateInstance() {
return new 读者表DataTable();
}
internal void InitVars() {
this.column读者号 = this.Columns["读者号"];
this.column读者姓名 = this.Columns["读者姓名"];
this.column读者性别 = this.Columns["读者性别"];
this.column读者班级 = this.Columns["读者班级"];
this.column借阅数目 = this.Columns["借阅数目"];
}
private void InitClass() {
this.column读者号 = new DataColumn("读者号", typeof(string), null, System.Data.MappingType.Element);
this.Columns.Add(this.column读者号);
this.column读者姓名 = new DataColumn("读者姓名", typeof(string), null, System.Data.MappingType.Element);
this.Columns.Add(this.column读者姓名);
this.column读者性别 = new DataColumn("读者性别", typeof(string), null, System.Data.MappingType.Element);
this.Columns.Add(this.column读者性别);
this.column读者班级 = new DataColumn("读者班级", typeof(string), null, System.Data.MappingType.Element);
this.Columns.Add(this.column读者班级);
this.column借阅数目 = new DataColumn("借阅数目", typeof(int), null, System.Data.MappingType.Element);
this.Columns.Add(this.column借阅数目);
this.Constraints.Add(new UniqueConstraint("Constraint1", new DataColumn[] {
this.column读者号}, true));
this.column读者号.AllowDBNull = false;
this.column读者号.Unique = true;
this.column读者姓名.AllowDBNull = false;
this.column读者性别.AllowDBNull = false;
this.column读者班级.AllowDBNull = false;
this.column借阅数目.AllowDBNull = false;
}
public 读者表Row New读者表Row() {
return ((读者表Row)(this.NewRow()));
}
protected override DataRow NewRowFromBuilder(DataRowBuilder builder) {
return new 读者表Row(builder);
}
protected override System.Type GetRowType() {
return typeof(读者表Row);
}
protected override void OnRowChanged(DataRowChangeEventArgs e) {
base.OnRowChanged(e);
if ((this.读者表RowChanged != null)) {
this.读者表RowChanged(this, new 读者表RowChangeEvent(((读者表Row)(e.Row)), e.Action));
}
}
protected override void OnRowChanging(DataRowChangeEventArgs e) {
base.OnRowChanging(e);
if ((this.读者表RowChanging != null)) {
this.读者表RowChanging(this, new 读者表RowChangeEvent(((读者表Row)(e.Row)), e.Action));
}
}
protected override void OnRowDeleted(DataRowChangeEventArgs e) {
base.OnRowDeleted(e);
if ((this.读者表RowDeleted != null)) {
this.读者表RowDeleted(this, new 读者表RowChangeEvent(((读者表Row)(e.Row)), e.Action));
}
}
protected override void OnRowDeleting(DataRowChangeEventArgs e) {
base.OnRowDeleting(e);
if ((this.读者表RowDeleting != null)) {
this.读者表RowDeleting(this, new 读者表RowChangeEvent(((读者表Row)(e.Row)), e.Action));
}
}
public void Remove读者表Row(读者表Row row) {
this.Rows.Remove(row);
}
}
[System.Diagnostics.DebuggerStepThrough()]
public class 读者表Row : DataRow {
private 读者表DataTable table读者表;
internal 读者表Row(DataRowBuilder rb) :
base(rb) {
this.table读者表 = ((读者表DataTable)(this.Table));
}
public string 读者号 {
get {
return ((string)(this[this.table读者表.读者号Column]));
}
set {
this[this.table读者表.读者号Column] = value;
}
}
public string 读者姓名 {
get {
return ((string)(this[this.table读者表.读者姓名Column]));
}
set {
this[this.table读者表.读者姓名Column] = value;
}
}
public string 读者性别 {
get {
return ((string)(this[this.table读者表.读者性别Column]));
}
set {
this[this.table读者表.读者性别Column] = value;
}
}
public string 读者班级 {
get {
return ((string)(this[this.table读者表.读者班级Column]));
}
set {
this[this.table读者表.读者班级Column] = value;
}
}
public int 借阅数目 {
get {
return ((int)(this[this.table读者表.借阅数目Column]));
}
set {
this[this.table读者表.借阅数目Column] = value;
}
}
}
[System.Diagnostics.DebuggerStepThrough()]
public class 读者表RowChangeEvent : EventArgs {
private 读者表Row eventRow;
private DataRowAction eventAction;
public 读者表RowChangeEvent(读者表Row row, DataRowAction action) {
this.eventRow = row;
this.eventAction = action;
}
public 读者表Row Row {
get {
return this.eventRow;
}
}
public DataRowAction Action {
get {
return this.eventAction;
}
}
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -