📄 bookback.cs
字号:
}
public TborrowinfoRow AddTborrowinfoRow(string readerid, string readername, string bookid, string bookname) {
TborrowinfoRow rowTborrowinfoRow = ((TborrowinfoRow)(this.NewRow()));
rowTborrowinfoRow.ItemArray = new object[] {
readerid,
readername,
bookid,
bookname};
this.Rows.Add(rowTborrowinfoRow);
return rowTborrowinfoRow;
}
public TborrowinfoRow FindByreaderid(string readerid) {
return ((TborrowinfoRow)(this.Rows.Find(new object[] {
readerid})));
}
public System.Collections.IEnumerator GetEnumerator() {
return this.Rows.GetEnumerator();
}
public override DataTable Clone() {
TborrowinfoDataTable cln = ((TborrowinfoDataTable)(base.Clone()));
cln.InitVars();
return cln;
}
protected override DataTable CreateInstance() {
return new TborrowinfoDataTable();
}
internal void InitVars() {
this.columnreaderid = this.Columns["readerid"];
this.columnreadername = this.Columns["readername"];
this.columnbookid = this.Columns["bookid"];
this.columnbookname = this.Columns["bookname"];
}
private void InitClass() {
this.columnreaderid = new DataColumn("readerid", typeof(string), null, System.Data.MappingType.Element);
this.Columns.Add(this.columnreaderid);
this.columnreadername = new DataColumn("readername", typeof(string), null, System.Data.MappingType.Element);
this.Columns.Add(this.columnreadername);
this.columnbookid = new DataColumn("bookid", typeof(string), null, System.Data.MappingType.Element);
this.Columns.Add(this.columnbookid);
this.columnbookname = new DataColumn("bookname", typeof(string), null, System.Data.MappingType.Element);
this.Columns.Add(this.columnbookname);
this.Constraints.Add(new UniqueConstraint("Constraint1", new DataColumn[] {
this.columnreaderid}, true));
this.columnreaderid.AllowDBNull = false;
this.columnreaderid.Unique = true;
}
public TborrowinfoRow NewTborrowinfoRow() {
return ((TborrowinfoRow)(this.NewRow()));
}
protected override DataRow NewRowFromBuilder(DataRowBuilder builder) {
return new TborrowinfoRow(builder);
}
protected override System.Type GetRowType() {
return typeof(TborrowinfoRow);
}
protected override void OnRowChanged(DataRowChangeEventArgs e) {
base.OnRowChanged(e);
if ((this.TborrowinfoRowChanged != null)) {
this.TborrowinfoRowChanged(this, new TborrowinfoRowChangeEvent(((TborrowinfoRow)(e.Row)), e.Action));
}
}
protected override void OnRowChanging(DataRowChangeEventArgs e) {
base.OnRowChanging(e);
if ((this.TborrowinfoRowChanging != null)) {
this.TborrowinfoRowChanging(this, new TborrowinfoRowChangeEvent(((TborrowinfoRow)(e.Row)), e.Action));
}
}
protected override void OnRowDeleted(DataRowChangeEventArgs e) {
base.OnRowDeleted(e);
if ((this.TborrowinfoRowDeleted != null)) {
this.TborrowinfoRowDeleted(this, new TborrowinfoRowChangeEvent(((TborrowinfoRow)(e.Row)), e.Action));
}
}
protected override void OnRowDeleting(DataRowChangeEventArgs e) {
base.OnRowDeleting(e);
if ((this.TborrowinfoRowDeleting != null)) {
this.TborrowinfoRowDeleting(this, new TborrowinfoRowChangeEvent(((TborrowinfoRow)(e.Row)), e.Action));
}
}
public void RemoveTborrowinfoRow(TborrowinfoRow row) {
this.Rows.Remove(row);
}
}
[System.Diagnostics.DebuggerStepThrough()]
public class TborrowinfoRow : DataRow {
private TborrowinfoDataTable tableTborrowinfo;
internal TborrowinfoRow(DataRowBuilder rb) :
base(rb) {
this.tableTborrowinfo = ((TborrowinfoDataTable)(this.Table));
}
public string readerid {
get {
return ((string)(this[this.tableTborrowinfo.readeridColumn]));
}
set {
this[this.tableTborrowinfo.readeridColumn] = value;
}
}
public string readername {
get {
try {
return ((string)(this[this.tableTborrowinfo.readernameColumn]));
}
catch (InvalidCastException e) {
throw new StrongTypingException("无法获取值,因为它是 DBNull。", e);
}
}
set {
this[this.tableTborrowinfo.readernameColumn] = value;
}
}
public string bookid {
get {
try {
return ((string)(this[this.tableTborrowinfo.bookidColumn]));
}
catch (InvalidCastException e) {
throw new StrongTypingException("无法获取值,因为它是 DBNull。", e);
}
}
set {
this[this.tableTborrowinfo.bookidColumn] = value;
}
}
public string bookname {
get {
try {
return ((string)(this[this.tableTborrowinfo.booknameColumn]));
}
catch (InvalidCastException e) {
throw new StrongTypingException("无法获取值,因为它是 DBNull。", e);
}
}
set {
this[this.tableTborrowinfo.booknameColumn] = value;
}
}
public bool IsreadernameNull() {
return this.IsNull(this.tableTborrowinfo.readernameColumn);
}
public void SetreadernameNull() {
this[this.tableTborrowinfo.readernameColumn] = System.Convert.DBNull;
}
public bool IsbookidNull() {
return this.IsNull(this.tableTborrowinfo.bookidColumn);
}
public void SetbookidNull() {
this[this.tableTborrowinfo.bookidColumn] = System.Convert.DBNull;
}
public bool IsbooknameNull() {
return this.IsNull(this.tableTborrowinfo.booknameColumn);
}
public void SetbooknameNull() {
this[this.tableTborrowinfo.booknameColumn] = System.Convert.DBNull;
}
}
[System.Diagnostics.DebuggerStepThrough()]
public class TborrowinfoRowChangeEvent : EventArgs {
private TborrowinfoRow eventRow;
private DataRowAction eventAction;
public TborrowinfoRowChangeEvent(TborrowinfoRow row, DataRowAction action) {
this.eventRow = row;
this.eventAction = action;
}
public TborrowinfoRow Row {
get {
return this.eventRow;
}
}
public DataRowAction Action {
get {
return this.eventAction;
}
}
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -