📄 dataset1.cs
字号:
this.columnscapename = this.Columns["scapename"];
this.columnpicture = this.Columns["picture"];
this.columnpresentation = this.Columns["presentation"];
this.columnprice = this.Columns["price"];
this.columnbus = this.Columns["bus"];
}
private void InitClass() {
this.columnscapeid = new DataColumn("scapeid", typeof(int), null, System.Data.MappingType.Element);
this.Columns.Add(this.columnscapeid);
this.columnscapename = new DataColumn("scapename", typeof(string), null, System.Data.MappingType.Element);
this.Columns.Add(this.columnscapename);
this.columnpicture = new DataColumn("picture", typeof(string), null, System.Data.MappingType.Element);
this.Columns.Add(this.columnpicture);
this.columnpresentation = new DataColumn("presentation", typeof(string), null, System.Data.MappingType.Element);
this.Columns.Add(this.columnpresentation);
this.columnprice = new DataColumn("price", typeof(string), null, System.Data.MappingType.Element);
this.Columns.Add(this.columnprice);
this.columnbus = new DataColumn("bus", typeof(string), null, System.Data.MappingType.Element);
this.Columns.Add(this.columnbus);
this.Constraints.Add(new UniqueConstraint("Constraint1", new DataColumn[] {
this.columnscapeid}, true));
this.columnscapeid.AllowDBNull = false;
this.columnscapeid.Unique = true;
this.columnscapename.AllowDBNull = false;
}
public scapeRow NewscapeRow() {
return ((scapeRow)(this.NewRow()));
}
protected override DataRow NewRowFromBuilder(DataRowBuilder builder) {
return new scapeRow(builder);
}
protected override System.Type GetRowType() {
return typeof(scapeRow);
}
protected override void OnRowChanged(DataRowChangeEventArgs e) {
base.OnRowChanged(e);
if ((this.scapeRowChanged != null)) {
this.scapeRowChanged(this, new scapeRowChangeEvent(((scapeRow)(e.Row)), e.Action));
}
}
protected override void OnRowChanging(DataRowChangeEventArgs e) {
base.OnRowChanging(e);
if ((this.scapeRowChanging != null)) {
this.scapeRowChanging(this, new scapeRowChangeEvent(((scapeRow)(e.Row)), e.Action));
}
}
protected override void OnRowDeleted(DataRowChangeEventArgs e) {
base.OnRowDeleted(e);
if ((this.scapeRowDeleted != null)) {
this.scapeRowDeleted(this, new scapeRowChangeEvent(((scapeRow)(e.Row)), e.Action));
}
}
protected override void OnRowDeleting(DataRowChangeEventArgs e) {
base.OnRowDeleting(e);
if ((this.scapeRowDeleting != null)) {
this.scapeRowDeleting(this, new scapeRowChangeEvent(((scapeRow)(e.Row)), e.Action));
}
}
public void RemovescapeRow(scapeRow row) {
this.Rows.Remove(row);
}
}
[System.Diagnostics.DebuggerStepThrough()]
public class scapeRow : DataRow {
private scapeDataTable tablescape;
internal scapeRow(DataRowBuilder rb) :
base(rb) {
this.tablescape = ((scapeDataTable)(this.Table));
}
public int scapeid {
get {
return ((int)(this[this.tablescape.scapeidColumn]));
}
set {
this[this.tablescape.scapeidColumn] = value;
}
}
public string scapename {
get {
return ((string)(this[this.tablescape.scapenameColumn]));
}
set {
this[this.tablescape.scapenameColumn] = value;
}
}
public string picture {
get {
try {
return ((string)(this[this.tablescape.pictureColumn]));
}
catch (InvalidCastException e) {
throw new StrongTypingException("无法获取值,因为它是 DBNull。", e);
}
}
set {
this[this.tablescape.pictureColumn] = value;
}
}
public string presentation {
get {
try {
return ((string)(this[this.tablescape.presentationColumn]));
}
catch (InvalidCastException e) {
throw new StrongTypingException("无法获取值,因为它是 DBNull。", e);
}
}
set {
this[this.tablescape.presentationColumn] = value;
}
}
public string price {
get {
try {
return ((string)(this[this.tablescape.priceColumn]));
}
catch (InvalidCastException e) {
throw new StrongTypingException("无法获取值,因为它是 DBNull。", e);
}
}
set {
this[this.tablescape.priceColumn] = value;
}
}
public string bus {
get {
try {
return ((string)(this[this.tablescape.busColumn]));
}
catch (InvalidCastException e) {
throw new StrongTypingException("无法获取值,因为它是 DBNull。", e);
}
}
set {
this[this.tablescape.busColumn] = value;
}
}
public bool IspictureNull() {
return this.IsNull(this.tablescape.pictureColumn);
}
public void SetpictureNull() {
this[this.tablescape.pictureColumn] = System.Convert.DBNull;
}
public bool IspresentationNull() {
return this.IsNull(this.tablescape.presentationColumn);
}
public void SetpresentationNull() {
this[this.tablescape.presentationColumn] = System.Convert.DBNull;
}
public bool IspriceNull() {
return this.IsNull(this.tablescape.priceColumn);
}
public void SetpriceNull() {
this[this.tablescape.priceColumn] = System.Convert.DBNull;
}
public bool IsbusNull() {
return this.IsNull(this.tablescape.busColumn);
}
public void SetbusNull() {
this[this.tablescape.busColumn] = System.Convert.DBNull;
}
}
[System.Diagnostics.DebuggerStepThrough()]
public class scapeRowChangeEvent : EventArgs {
private scapeRow eventRow;
private DataRowAction eventAction;
public scapeRowChangeEvent(scapeRow row, DataRowAction action) {
this.eventRow = row;
this.eventAction = action;
}
public scapeRow Row {
get {
return this.eventRow;
}
}
public DataRowAction Action {
get {
return this.eventAction;
}
}
}
[System.Diagnostics.DebuggerStepThrough()]
public class rummeryDataTable : DataTable, System.Collections.IEnumerable {
private DataColumn columnrummeryid;
private DataColumn columnrummeryname;
private DataColumn columnpicture;
private DataColumn columncontent;
private DataColumn columnstar;
private DataColumn columnaddress;
private DataColumn columntelephone;
internal rummeryDataTable() :
base("rummery") {
this.InitClass();
}
internal rummeryDataTable(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 rummeryidColumn {
get {
return this.columnrummeryid;
}
}
internal DataColumn rummerynameColumn {
get {
return this.columnrummeryname;
}
}
internal DataColumn pictureColumn {
get {
return this.columnpicture;
}
}
internal DataColumn contentColumn {
get {
return this.columncontent;
}
}
internal DataColumn starColumn {
get {
return this.columnstar;
}
}
internal DataColumn addressColumn {
get {
return this.columnaddress;
}
}
internal DataColumn telephoneColumn {
get {
return this.columntelephone;
}
}
public rummeryRow this[int index] {
get {
return ((rummeryRow)(this.Rows[index]));
}
}
public event rummeryRowChangeEventHandler rummeryRowChanged;
public event rummeryRowChangeEventHandler rummeryRowChanging;
public event rummeryRowChangeEventHandler rummeryRowDeleted;
public event rummeryRowChangeEventHandler rummeryRowDeleting;
public void AddrummeryRow(rummeryRow row) {
this.Rows.Add(row);
}
public rummeryRow AddrummeryRow(int rummeryid, string rummeryname, string picture, string content, string star, string address, string telephone) {
rummeryRow rowrummeryRow = ((rummeryRow)(this.NewRow()));
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -