DataSet2.cs
资源名称:VCSDB.rar [点击查看]
上传用户:hjieqiu
上传日期:2013-05-11
资源大小:16494k
文件大小:24k
源码类别:
企业管理
开发平台:
C#
- //------------------------------------------------------------------------------
- // <autogenerated>
- // This code was generated by a tool.
- // Runtime Version: 1.1.4322.573
- //
- // Changes to this file may cause incorrect behavior and will be lost if
- // the code is regenerated.
- // </autogenerated>
- //------------------------------------------------------------------------------
- namespace 教务管理系统 {
- using System;
- using System.Data;
- using System.Xml;
- using System.Runtime.Serialization;
- [Serializable()]
- [System.ComponentModel.DesignerCategoryAttribute("code")]
- [System.Diagnostics.DebuggerStepThrough()]
- [System.ComponentModel.ToolboxItem(true)]
- public class DataSet2 : DataSet {
- private 班级信息DataTable table班级信息;
- public DataSet2() {
- this.InitClass();
- System.ComponentModel.CollectionChangeEventHandler schemaChangedHandler = new System.ComponentModel.CollectionChangeEventHandler(this.SchemaChanged);
- this.Tables.CollectionChanged += schemaChangedHandler;
- this.Relations.CollectionChanged += schemaChangedHandler;
- }
- protected DataSet2(SerializationInfo info, StreamingContext context) {
- string strSchema = ((string)(info.GetValue("XmlSchema", typeof(string))));
- if ((strSchema != null)) {
- DataSet ds = new DataSet();
- ds.ReadXmlSchema(new XmlTextReader(new System.IO.StringReader(strSchema)));
- if ((ds.Tables["班级信息"] != null)) {
- this.Tables.Add(new 班级信息DataTable(ds.Tables["班级信息"]));
- }
- this.DataSetName = ds.DataSetName;
- this.Prefix = ds.Prefix;
- this.Namespace = ds.Namespace;
- this.Locale = ds.Locale;
- this.CaseSensitive = ds.CaseSensitive;
- this.EnforceConstraints = ds.EnforceConstraints;
- this.Merge(ds, false, System.Data.MissingSchemaAction.Add);
- this.InitVars();
- }
- else {
- this.InitClass();
- }
- this.GetSerializationData(info, context);
- System.ComponentModel.CollectionChangeEventHandler schemaChangedHandler = new System.ComponentModel.CollectionChangeEventHandler(this.SchemaChanged);
- this.Tables.CollectionChanged += schemaChangedHandler;
- this.Relations.CollectionChanged += schemaChangedHandler;
- }
- [System.ComponentModel.Browsable(false)]
- [System.ComponentModel.DesignerSerializationVisibilityAttribute(System.ComponentModel.DesignerSerializationVisibility.Content)]
- public 班级信息DataTable 班级信息 {
- get {
- return this.table班级信息;
- }
- }
- public override DataSet Clone() {
- DataSet2 cln = ((DataSet2)(base.Clone()));
- cln.InitVars();
- return cln;
- }
- protected override bool ShouldSerializeTables() {
- return false;
- }
- protected override bool ShouldSerializeRelations() {
- return false;
- }
- protected override void ReadXmlSerializable(XmlReader reader) {
- this.Reset();
- DataSet ds = new DataSet();
- ds.ReadXml(reader);
- if ((ds.Tables["班级信息"] != null)) {
- this.Tables.Add(new 班级信息DataTable(ds.Tables["班级信息"]));
- }
- this.DataSetName = ds.DataSetName;
- this.Prefix = ds.Prefix;
- this.Namespace = ds.Namespace;
- this.Locale = ds.Locale;
- this.CaseSensitive = ds.CaseSensitive;
- this.EnforceConstraints = ds.EnforceConstraints;
- this.Merge(ds, false, System.Data.MissingSchemaAction.Add);
- this.InitVars();
- }
- protected override System.Xml.Schema.XmlSchema GetSchemaSerializable() {
- System.IO.MemoryStream stream = new System.IO.MemoryStream();
- this.WriteXmlSchema(new XmlTextWriter(stream, null));
- stream.Position = 0;
- return System.Xml.Schema.XmlSchema.Read(new XmlTextReader(stream), null);
- }
- internal void InitVars() {
- this.table班级信息 = ((班级信息DataTable)(this.Tables["班级信息"]));
- if ((this.table班级信息 != null)) {
- this.table班级信息.InitVars();
- }
- }
- private void InitClass() {
- this.DataSetName = "DataSet2";
- this.Prefix = "";
- this.Namespace = "http://www.tempuri.org/DataSet2.xsd";
- this.Locale = new System.Globalization.CultureInfo("zh-CN");
- this.CaseSensitive = false;
- this.EnforceConstraints = true;
- this.table班级信息 = new 班级信息DataTable();
- this.Tables.Add(this.table班级信息);
- }
- private bool ShouldSerialize班级信息() {
- return false;
- }
- private void SchemaChanged(object sender, System.ComponentModel.CollectionChangeEventArgs e) {
- if ((e.Action == System.ComponentModel.CollectionChangeAction.Remove)) {
- this.InitVars();
- }
- }
- public delegate void 班级信息RowChangeEventHandler(object sender, 班级信息RowChangeEvent e);
- [System.Diagnostics.DebuggerStepThrough()]
- public class 班级信息DataTable : DataTable, System.Collections.IEnumerable {
- private DataColumn column班级编号;
- private DataColumn column班级名称;
- private DataColumn column籍贯编号;
- private DataColumn column籍贯;
- private DataColumn column民族编号;
- private DataColumn column民族;
- private DataColumn column学籍编号;
- private DataColumn column学籍名称;
- private DataColumn column政治面貌编号;
- private DataColumn column政治面貌;
- 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民族编号;
- }
- }
- 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 籍贯, string 民族编号, string 民族, string 学籍编号, string 学籍名称, string 政治面貌编号, string 政治面貌) {
- 班级信息Row row班级信息Row = ((班级信息Row)(this.NewRow()));
- row班级信息Row.ItemArray = new object[] {
- 班级编号,
- 班级名称,
- 籍贯编号,
- 籍贯,
- 民族编号,
- 民族,
- 学籍编号,
- 学籍名称,
- 政治面貌编号,
- 政治面貌};
- this.Rows.Add(row班级信息Row);
- return row班级信息Row;
- }
- public 班级信息Row FindBy班级编号籍贯编号民族编号学籍编号政治面貌编号(string 班级编号, string 籍贯编号, string 民族编号, string 学籍编号, 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["民族编号"];
- 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(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(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.Constraints.Add(new UniqueConstraint("Constraint1", new DataColumn[] {
- this.column班级编号,
- this.column籍贯编号,
- this.column民族编号,
- this.column学籍编号,
- this.column政治面貌编号}, true));
- this.column班级编号.AllowDBNull = false;
- 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 {
- try {
- return ((string)(this[this.table班级信息.班级名称Column]));
- }
- catch (InvalidCastException e) {
- throw new StrongTypingException("无法获取值,因为它是 DBNull。", e);
- }
- }
- set {
- this[this.table班级信息.班级名称Column] = value;
- }
- }
- public string 籍贯编号 {
- get {
- return ((string)(this[this.table班级信息.籍贯编号Column]));
- }
- set {
- this[this.table班级信息.籍贯编号Column] = value;
- }
- }
- public string 籍贯 {
- get {
- try {
- return ((string)(this[this.table班级信息.籍贯Column]));
- }
- catch (InvalidCastException e) {
- throw new StrongTypingException("无法获取值,因为它是 DBNull。", e);
- }
- }
- set {
- this[this.table班级信息.籍贯Column] = value;
- }
- }
- public string 民族编号 {
- get {
- return ((string)(this[this.table班级信息.民族编号Column]));
- }
- set {
- this[this.table班级信息.民族编号Column] = value;
- }
- }
- public string 民族 {
- get {
- try {
- return ((string)(this[this.table班级信息.民族Column]));
- }
- catch (InvalidCastException e) {
- throw new StrongTypingException("无法获取值,因为它是 DBNull。", e);
- }
- }
- set {
- this[this.table班级信息.民族Column] = value;
- }
- }
- public string 学籍编号 {
- get {
- return ((string)(this[this.table班级信息.学籍编号Column]));
- }
- set {
- this[this.table班级信息.学籍编号Column] = value;
- }
- }
- public string 学籍名称 {
- get {
- try {
- return ((string)(this[this.table班级信息.学籍名称Column]));
- }
- catch (InvalidCastException e) {
- throw new StrongTypingException("无法获取值,因为它是 DBNull。", e);
- }
- }
- set {
- this[this.table班级信息.学籍名称Column] = value;
- }
- }
- public string 政治面貌编号 {
- get {
- return ((string)(this[this.table班级信息.政治面貌编号Column]));
- }
- set {
- this[this.table班级信息.政治面貌编号Column] = value;
- }
- }
- public string 政治面貌 {
- get {
- try {
- return ((string)(this[this.table班级信息.政治面貌Column]));
- }
- catch (InvalidCastException e) {
- throw new StrongTypingException("无法获取值,因为它是 DBNull。", e);
- }
- }
- set {
- this[this.table班级信息.政治面貌Column] = value;
- }
- }
- public bool Is班级名称Null() {
- return this.IsNull(this.table班级信息.班级名称Column);
- }
- public void Set班级名称Null() {
- this[this.table班级信息.班级名称Column] = System.Convert.DBNull;
- }
- public bool Is籍贯Null() {
- return this.IsNull(this.table班级信息.籍贯Column);
- }
- public void Set籍贯Null() {
- this[this.table班级信息.籍贯Column] = System.Convert.DBNull;
- }
- public bool Is民族Null() {
- return this.IsNull(this.table班级信息.民族Column);
- }
- public void Set民族Null() {
- this[this.table班级信息.民族Column] = System.Convert.DBNull;
- }
- public bool Is学籍名称Null() {
- return this.IsNull(this.table班级信息.学籍名称Column);
- }
- public void Set学籍名称Null() {
- this[this.table班级信息.学籍名称Column] = System.Convert.DBNull;
- }
- public bool Is政治面貌Null() {
- return this.IsNull(this.table班级信息.政治面貌Column);
- }
- public void Set政治面貌Null() {
- this[this.table班级信息.政治面貌Column] = System.Convert.DBNull;
- }
- }
- [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;
- }
- }
- }
- }
- }