//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:2.0.50727.1433
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
#pragma warning disable 1591
namespace ASPNET_MVC_Store.Model {
/// <summary>
///Represents a strongly typed in-memory cache of data.
///</summary>
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "2.0.0.0")]
[global::System.Serializable()]
[global::System.ComponentModel.DesignerCategoryAttribute("code")]
[global::System.ComponentModel.ToolboxItem(true)]
[global::System.Xml.Serialization.XmlSchemaProviderAttribute("GetTypedDataSetSchema")]
[global::System.Xml.Serialization.XmlRootAttribute("NorthwindDataSet")]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.DataSet")]
public partial class NorthwindDataSet : global::System.Data.DataSet {
private CategoriesDataTable tableCategories;
private ProductsDataTable tableProducts;
private SuppliersDataTable tableSuppliers;
private global::System.Data.DataRelation relationCategoriesProducts;
private global::System.Data.DataRelation relationSuppliersProducts;
private global::System.Data.SchemaSerializationMode _schemaSerializationMode = global::System.Data.SchemaSerializationMode.IncludeSchema;
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public NorthwindDataSet() {
this.BeginInit();
this.InitClass();
global::System.ComponentModel.CollectionChangeEventHandler schemaChangedHandler = new global::System.ComponentModel.CollectionChangeEventHandler(this.SchemaChanged);
base.Tables.CollectionChanged += schemaChangedHandler;
base.Relations.CollectionChanged += schemaChangedHandler;
this.EndInit();
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected NorthwindDataSet(global::System.Runtime.Serialization.SerializationInfo info, global::System.Runtime.Serialization.StreamingContext context) :
base(info, context, false) {
if ((this.IsBinarySerialized(info, context) == true)) {
this.InitVars(false);
global::System.ComponentModel.CollectionChangeEventHandler schemaChangedHandler1 = new global::System.ComponentModel.CollectionChangeEventHandler(this.SchemaChanged);
this.Tables.CollectionChanged += schemaChangedHandler1;
this.Relations.CollectionChanged += schemaChangedHandler1;
return;
}
string strSchema = ((string)(info.GetValue("XmlSchema", typeof(string))));
if ((this.DetermineSchemaSerializationMode(info, context) == global::System.Data.SchemaSerializationMode.IncludeSchema)) {
global::System.Data.DataSet ds = new global::System.Data.DataSet();
ds.ReadXmlSchema(new global::System.Xml.XmlTextReader(new global::System.IO.StringReader(strSchema)));
if ((ds.Tables["Categories"] != null)) {
base.Tables.Add(new CategoriesDataTable(ds.Tables["Categories"]));
}
if ((ds.Tables["Products"] != null)) {
base.Tables.Add(new ProductsDataTable(ds.Tables["Products"]));
}
if ((ds.Tables["Suppliers"] != null)) {
base.Tables.Add(new SuppliersDataTable(ds.Tables["Suppliers"]));
}
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, global::System.Data.MissingSchemaAction.Add);
this.InitVars();
}
else {
this.ReadXmlSchema(new global::System.Xml.XmlTextReader(new global::System.IO.StringReader(strSchema)));
}
this.GetSerializationData(info, context);
global::System.ComponentModel.CollectionChangeEventHandler schemaChangedHandler = new global::System.ComponentModel.CollectionChangeEventHandler(this.SchemaChanged);
base.Tables.CollectionChanged += schemaChangedHandler;
this.Relations.CollectionChanged += schemaChangedHandler;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Browsable(false)]
[global::System.ComponentModel.DesignerSerializationVisibility(global::System.ComponentModel.DesignerSerializationVisibility.Content)]
public CategoriesDataTable Categories {
get {
return this.tableCategories;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Browsable(false)]
[global::System.ComponentModel.DesignerSerializationVisibility(global::System.ComponentModel.DesignerSerializationVisibility.Content)]
public ProductsDataTable Products {
get {
return this.tableProducts;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Browsable(false)]
[global::System.ComponentModel.DesignerSerializationVisibility(global::System.ComponentModel.DesignerSerializationVisibility.Content)]
public SuppliersDataTable Suppliers {
get {
return this.tableSuppliers;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.BrowsableAttribute(true)]
[global::System.ComponentModel.DesignerSerializationVisibilityAttribute(global::System.ComponentModel.DesignerSerializationVisibility.Visible)]
public override global::System.Data.SchemaSerializationMode SchemaSerializationMode {
get {
return this._schemaSerializationMode;
}
set {
this._schemaSerializationMode = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.DesignerSerializationVisibilityAttribute(global::System.ComponentModel.DesignerSerializationVisibility.Hidden)]
public new global::System.Data.DataTableCollection Tables {
get {
return base.Tables;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.DesignerSerializationVisibilityAttribute(global::System.ComponentModel.DesignerSerializationVisibility.Hidden)]
public new global::System.Data.DataRelationCollection Relations {
get {
return base.Relations;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected override void InitializeDerivedDataSet() {
this.BeginInit();
this.InitClass();
this.EndInit();
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public override global::System.Data.DataSet Clone() {
NorthwindDataSet cln = ((NorthwindDataSet)(base.Clone()));
cln.InitVars();
cln.SchemaSerializationMode = this.SchemaSerializationMode;
return cln;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected override bool ShouldSerializeTables() {
return false;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected override bool ShouldSerializeRelations() {
return false;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected override void ReadXmlSerializable(global::System.Xml.XmlReader reader) {
if ((this.DetermineSchemaSerializationMode(reader) == global::System.Data.SchemaSerializationMode.IncludeSchema)) {
this.Reset();
global::System.Data.DataSet ds = new global::System.Data.DataSet();
ds.ReadXml(reader);
if ((ds.Tables["Categories"] != null)) {
base.Tables.Add(new CategoriesDataTable(ds.Tables["Categories"]));
}
if ((ds.Tables["Products"] != null)) {
base.Tables.Add(new ProductsDataTable(ds.Tables["Products"]));
}
if ((ds.Tables["Suppliers"] != null)) {
base.Tables.Add(new SuppliersDataTable(ds.Tables["Suppliers"]));
}
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, global::System.Data.MissingSchemaAction.Add);
this.InitVars();
}
else {
this.ReadXml(reader);
this.InitVars();
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected override global::System.Xml.Schema.XmlSchema GetSchemaSerializable() {
global::System.IO.MemoryStream stream = new global::System.IO.MemoryStream();
this.WriteXmlSchema(new global::System.Xml.XmlTextWriter(stream, null));
stream.Position = 0;
return global::System.Xml.Schema.XmlSchema.Read(new global::System.Xml.XmlTextReader(stream), null);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
internal void InitVars() {
this.InitVars(true);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
internal void InitVars(bool initTable) {
this.tableCategories = ((CategoriesDataTable)(base.Tables["Categories"]));
if ((initTable == true)) {
if ((this.tableCategories != null)) {
this.tableCategories.InitVars();
}
}
this.tableProducts = ((ProductsDataTable)(base.Tables["Products"]));
if ((initTable == true)) {
if ((this.tableProducts != null)) {
this.tableProducts.InitVars();
}
}
this.tableSuppliers = ((SuppliersDataTable)(base.Tables["Suppliers"]));
if ((initTable == true)) {
if ((this.tableSuppliers != null)) {
this.tableSuppliers.InitVars();
}
}
this.relationCategoriesProducts = this.Relations["CategoriesProducts"];
this.relationSuppliersProducts = this.Relations["SuppliersProducts"];
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
private void InitClass() {
this.DataSetName = "NorthwindDataSet";
this.Prefix = "";
this.Namespace = "http://tempuri.org/NorthwindDataSet.xsd";
this.EnforceConstraints = true;
this.SchemaSerializationMode = global::System.Data.SchemaSerializationMode.IncludeSchema;
this.tableCategories = new CategoriesDataTable();
base.Tables.Add(this.tableCategories);
this.tableProducts = new ProductsDataTable();
base.Tables.Add(this.tableProducts);
this.tableSuppliers = new SuppliersDataTable();
base.Tables.Add(this.tableSuppliers);
this.relationCategoriesProducts = new global::System.Data.DataRelation("CategoriesProducts", new global::System.Data.DataColumn[] {
this.tableCategories.CategoryIDColumn}, new global::System.Data.DataColumn[] {
this.tableProducts.CategoryIDColumn}, false);
this.Relations.Add(this.relationCategoriesProducts);
this.relationSuppliersProducts = new global::System.Data.DataRelation("SuppliersProducts", new global::System.Data.DataColumn[] {
this.tableSuppliers.SupplierIDColumn}, new global::System.Data.DataColumn[] {
this.tableProducts.SupplierIDColumn}, false);
this.Relations.Add(this.relationSuppliersProducts);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
private bool ShouldSerializeCategories() {
return false;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
private bool ShouldSerializeProducts() {
return false;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
private bool ShouldSerializeSuppliers() {
return false;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
private void SchemaChanged(object sender, global::System.ComponentModel.CollectionChangeEventArgs e) {
if ((e.Action == global::System.ComponentModel.CollectionChangeAction.Remove)) {
this.InitVars();
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static global::System.Xml.Schema.XmlSchemaComplexType GetTypedDataSetSchema(global::System.Xml.Schema.XmlSchemaSet xs) {
NorthwindDataSet ds = new NorthwindDataSet();
global::System.Xml.Schema.XmlSchemaComplexType type = new global::System.Xml.Schema.XmlSchemaComplexType();
global::System.Xml.Schema.XmlSchemaSequence sequence = new global::System.Xml.Schema.XmlSchemaSequence();
global::System.Xml.Schema.XmlSchemaAny any = new global::System.Xml.Schema.XmlSchemaAny();
any.Namespace = ds.Namespace;
sequence.Items.Add(any);
type.Particle = sequence;
global::System.Xml.Schema.XmlSchema dsSchema = ds.GetSchemaSerializable();
if (xs.Contains(dsSchema.TargetNamespace)) {
global::System.IO.MemoryStream s1 = new global::System.IO.MemoryStream();
global::System.IO.MemoryStream s2 = new global::System.IO.MemoryStream();
try {
global::System.Xml.Schema.XmlSchema schema = null;
dsSchema.Write(s1);
for (global::System.Collections.IEnumerator schemas = xs.Schemas(dsSchema.TargetNamespace).GetEnumerator(); schemas.MoveNext(); ) {
schema = ((global::System.Xml.Schema.XmlSchema)(schemas.Current));
s2.SetLength(0);
schema.Write(s2);
if ((s1.Length == s2.Length)) {
s1.Position = 0;
s2.Position = 0;
for (; ((s1.Position != s1.Length)
&& (s1.ReadByte() == s2.ReadByte())); ) {
;
}
if ((s1.Position == s1.Length)) {
return type;
}
}
}
}
finally {
if ((s1 != null)) {
s1.Close();
}
if ((s2 != null)) {
s2.Close();
}
}
}
xs.Add(dsSchema);
return type;
}
public delegate void CategoriesRowChangeEventHandler(object sender, CategoriesRowChangeEvent e);
public delegate void ProductsRowChangeEventHandler(object sender, ProductsRowChangeEvent e);
public delegate void SuppliersRowChangeEventHandler(object sender, SuppliersRowChangeEvent e);
/// <summary>
///Represents the strongly named DataTable class.
///</summary>
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "2.0.0.0")]
[global::System.Serializable()]
[global::System.Xml.Serialization.XmlSchemaProviderAttribute("GetTypedTableSchema")]
public partial class CategoriesDataTable : global::System.Data.DataTable, global::System.Collections.IEnumerable {
private global::System.Data.DataColumn columnCategoryID;
private global::System.Data.DataColumn columnCategoryName;
private global::System.Data.DataColumn columnDescription;
private global::System.Data.DataColumn columnPicture;
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public CategoriesDataTable() {
this.TableName = "Categories";
this.BeginInit();
this.InitClass();
this.EndInit();
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
internal CategoriesDataTable(global::System.Data.DataTable table) {
this.TableName = 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;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected CategoriesDataTable(global::System.Runtime.Serialization.SerializationInfo info, global::System.Runtime.Serialization.StreamingContext context) :
base(info, context) {
this.InitVars();
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public global::System.Data.DataColumn CategoryIDColumn {
get {
return this.columnCategoryID;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public global::System.Data.DataColumn CategoryNameColumn {
get {
return this.columnCategoryName;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public global::System.Data.DataColumn DescriptionColumn {
get {
return this.columnDescription;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public global::System.Data.DataColumn PictureColumn {
get {
return this.columnPicture;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Browsable(false)]
public int Count {
get {
return this.Rows.Count;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public CategoriesRow this[int index] {
get {
return ((CategoriesRow)(this.Rows[index]));
}
}
public event CategoriesRowChangeEventHandler CategoriesRowChanging;
public event CategoriesRowChangeEventHandler CategoriesRowChanged;
public event CategoriesRowChangeEventHandler CategoriesRowDeleting;
public event CategoriesRowChangeEventHandler CategoriesRowDeleted;
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void AddCategoriesRow(CategoriesRow row) {
this.Rows.Add(row);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public CategoriesRow AddCategoriesRow(string CategoryName, string Description, byte[] Picture) {
CategoriesRow rowCategoriesRow = ((CategoriesRow)(this.NewRow()));
object[] columnValuesArray = new object[] {
null,
CategoryName,
Description,
Picture};
rowCategoriesRow.ItemArray = columnValuesArray;
this.Rows.Add(rowCategoriesRow);
return rowCategoriesRow;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public CategoriesRow FindByCategoryID(int CategoryID) {
return ((CategoriesRow)(this.Rows.Find(new object[] {
CategoryID})));
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public virtual global::System.Collections.IEnumerator GetEnumerator() {
return this.Rows.GetEnumerator();
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public override global::System.Data.DataTable Clone() {
CategoriesDataTable cln = ((CategoriesDataTable)(base.Clone()));
cln.InitVars();
return cln;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected override global::System.Data.DataTable CreateInstance() {
return new CategoriesDataTable();
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
internal void InitVars() {
this.columnCategoryID = base.Columns["CategoryID"];
this.columnCategoryName = base.Columns["CategoryName"];
this.columnDescription = base.Columns["Description"];
this.columnPicture = base.Columns["Picture"];
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
private void InitClass() {
this.columnCategoryID = new global::System.Data.DataColumn("CategoryID", typeof(int), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnCategoryID);
this.columnCategoryName = new global::System.Data.DataColumn("CategoryName", typeof(string), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnCategoryName);
this.columnDescription = new global::System.Data.DataColumn("Description", typeof(string), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnDescription);
this.columnPicture = new global::System.Data.DataColumn("Picture", typeof(byte[]), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnPicture);
this.Constraints.Add(new global::System.Data.UniqueConstraint("Constraint1", new global::System.Data.DataColumn[] {
this.columnCategoryID}, true));
this.columnCategoryID.AutoIncrement = true;
this.columnCategoryID.AllowDBNull = false;
this.columnCategoryID.Unique = true;
this.columnCategoryName.MaxLength = 15;
this.columnDescription.MaxLength = 536870910;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public CategoriesRow NewCategoriesRow() {
return ((CategoriesRow)(this.NewRow()));
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected override global::System.Data.DataRow NewRowFromBuilder(global::System.Data.DataRowBuilder builder) {
return new CategoriesRow(builder);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected override global::System.Type GetRowType() {
return typeof(CategoriesRow);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected override void OnRowChanged(global::System.Data.DataRowChangeEventArgs e) {
base.OnRowChanged(e);
if ((this.CategoriesRowChanged != null)) {
this.CategoriesRowChanged(this, new CategoriesRowChangeEvent(((CategoriesRow)(e.Row)), e.Action));
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected override void OnRowChanging(global::System.Data.DataRowChangeEventArgs e) {
base.OnRowChanging(e);
if ((this.CategoriesRowChanging != null)) {
this.CategoriesRowChanging(this, new CategoriesRowChangeEvent(((CategoriesRow)(e.Row)), e.Action));
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected override void OnRowDeleted(global::System.Data.DataRowChangeEventArgs e) {
base.OnRowDeleted(e);
if ((this.CategoriesRowDeleted != null)) {
this.CategoriesRowDeleted(this, new CategoriesRowChangeEvent(((CategoriesRow)(e.Row)), e.Action));
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected override void OnRowDeleting(global::System.Data.DataRowChangeEventArgs e) {
base.OnRowDeleting(e);
if ((this.CategoriesRowDeleting != null)) {
this.CategoriesRowDeleting(this, new CategoriesRowChangeEvent(((CategoriesRow)(e.Row)), e.Action));
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void RemoveCategoriesRow(CategoriesRow row) {
this.Rows.Remove(row);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static global::System.Xml.Schema.XmlSchemaComplexType GetTypedTableSchema(global::System.Xml.Schema.XmlSchemaSet xs) {
global::System.Xml.Schema.XmlSchemaComplexType type = new global::System.Xml.Schema.XmlSchemaComplexType();
global::System.Xml.Schema.XmlSchemaSequence sequence = new global::System.Xml.Schema.XmlSchemaSequence();
NorthwindDataSet ds = new NorthwindDataSet();
global::System.Xml.Schema.XmlSchemaAny any1 = new global::System.Xml.Schema.XmlSchemaAny();
any1.Namespace = "http://www.w3.org/2001/XMLSchema";
any1.MinOccurs = new decimal(0);
any1.MaxOccurs = decimal.MaxValue;
any1.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
sequence.Items.Add(any1);
global::System.Xml.Schema.XmlSchemaAny any2 = new global::System.Xml.Schema.XmlSchemaAny();
any2.Namespace = "urn:schemas-microsoft-com:xml-diffgram-v1";
any2.MinOccurs = new decimal(1);
any2.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
sequence.Items.Add(any2);
global::System.Xml.Schema.XmlSchemaAttribute attribute1 = new global::System.Xml.Schema.XmlSchemaAttribute();
attribute1.Name = "namespace";
attribute1.FixedValue = ds.Namespace;
type.Attributes.Add(attribute1);
global::System.Xml.Schema.XmlSchemaAttribute attribute2 = new global::System.Xml.Schema.XmlSchemaAttribute();
attribute2.Name = "tableTypeName";
attribute2.FixedValue = "CategoriesDataTable";
type.Attributes.Add(attribute2);
type.Particle = sequence;
global::System.Xml.Schema.XmlSchema dsSchema = ds.GetSchemaSerializable();
if (xs.Contains(dsSchema.TargetNamespace)) {
global::System.IO.MemoryStream s1 = new global::System.IO.MemoryStream();
global::System.IO.MemoryStream s2 = new global::System.IO.MemoryStream();
try {
global::System.Xml.Schema.XmlSchema schema = null;
dsSchema.Write(s1);
for (global::System.Collections.IEnumerator schemas = xs.Schemas(dsSchema.TargetNamespace).GetEnumerator(); schemas.MoveNext(); ) {
schema = ((global::System.Xml.Schema.XmlSchema)(schemas.Current));
s2.SetLength(0);
schema.Write(s2);
if ((s1.Length == s2.Length)) {
s1.Position = 0;
s2.Position = 0;
for (; ((s1.Position != s1.Length)
&& (s1.ReadByte() == s2.ReadByte())); ) {
;
}
if ((s1.Position == s1.Length)) {
return type;
}
}
}
}
finally {
if ((s1 != null)) {
s1.Close();
}
if ((s2 != null)) {
s2.Close();
}
}
}
xs.Add(dsSchema);
return type;
}
}
/// <summary>
///Represents the strongly named DataTable class.
///</summary>
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "2.0.0.0")]
[global::System.Serializable()]
[global::System.Xml.Serialization.XmlSchemaProviderAttribute("GetTypedTableSchema")]
public partial class ProductsDataTable : global::System.Data.DataTable, global::System.Collections.IEnumerable {
private global::System.Data.DataColumn columnProductID;
private global::System.Data.DataColumn columnProductName;
private global::System.Data.DataColumn columnSupplierID;
private global::System.Data.DataColumn columnCategoryID;
private global::System.Data.DataColumn columnQuantityPerUnit;
private global::System.Data.DataColumn columnUnitPrice;
private global::System.Data.DataColumn columnUnitsInStock;
private global::System.Data.DataColumn columnUnitsOnOrder;
private global::System.Data.DataColumn columnReorderLevel;
private global::System.Data.DataColumn columnDiscontinued;
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public ProductsDataTable() {
this.TableName = "Products";
this.BeginInit();
this.InitClass();
this.EndInit();
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
internal ProductsDataTable(global::System.Data.DataTable table) {
this.TableName = 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;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected ProductsDataTable(global::System.Runtime.Serialization.SerializationInfo info, global::System.Runtime.Serialization.StreamingContext context) :
base(info, context) {
this.InitVars();
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public global::System.Data.DataColumn ProductIDColumn {
get {
return this.columnProductID;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public global::System.Data.DataColumn ProductNameColumn {
get {
return this.columnProductName;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public global::System.Data.DataColumn SupplierIDColumn {
get {
return this.columnSupplierID;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public global::System.Data.DataColumn CategoryIDColumn {
get {
return this.columnCategoryID;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public global::System.Data.DataColumn QuantityPerUnitColumn {
get {
return this.columnQuantityPerUnit;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public global::System.Data.DataColumn UnitPriceColumn {
get {
return this.columnUnitPrice;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public global::System.Data.DataColumn UnitsInStockColumn {
get {
return this.columnUnitsInStock;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public global::System.Data.DataColumn UnitsOnOrderColumn {
get {
return this.columnUnitsOnOrder;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public global::System.Data.DataColumn ReorderLevelColumn {
get {
return this.columnReorderLevel;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public global::System.Data.DataColumn DiscontinuedColumn {
get {
return this.columnDiscontinued;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Browsable(false)]
public int Count {
get {
return this.Rows.Count;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public ProductsRow this[int index] {
get {
return ((ProductsRow)(this.Rows[index]));
}
}
public event ProductsRowChangeEventHandler ProductsRowChanging;
public event ProductsRowChangeEventHandler ProductsRowChanged;
public event ProductsRowChangeEventHandler ProductsRowDeleting;
public event ProductsRowChangeEventHandler ProductsRowDeleted;
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void AddProductsRow(ProductsRow row) {
this.Rows.Add(row);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public ProductsRow AddProductsRow(string ProductName, SuppliersRow parentSuppliersRowBySuppliersProducts, CategoriesRow parentCategoriesRowByCategoriesProducts, string QuantityPerUnit, decimal UnitPrice, short UnitsInStock, short UnitsOnOrder, short ReorderLevel, bool Discontinued) {
ProductsRow rowProductsRow = ((ProductsRow)(this.NewRow()));
object[] columnValuesArray = new object[] {
null,
ProductName,
null,
null,
QuantityPerUnit,
UnitPrice,
UnitsInStock,
UnitsOnOrder,
ReorderLevel,
Discontinued};
if ((parentSuppliersRowBySuppliersProducts != null)) {
columnValuesArray[2] = parentSuppliersRowBySuppliersProducts[0];
}
if ((parentCategoriesRowByCategoriesProducts != null)) {
columnValuesArray[3] = parentCategoriesRowByCategoriesProducts[0];
}
rowProductsRow.ItemArray = columnValuesArray;
this.Rows.Add(rowProductsRow);
return rowProductsRow;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public ProductsRow FindByProductID(int ProductID) {
return ((ProductsRow)(this.Rows.Find(new object[] {
ProductID})));
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public virtual global::System.Collections.IEnumerator GetEnumerator() {
return this.Rows.GetEnumerator();
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public override global::System.Data.DataTable Clone() {
ProductsDataTable cln = ((ProductsDataTable)(base.Clone()));
cln.InitVars();
return cln;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected override global::System.Data.DataTable CreateInstance() {
return new ProductsDataTable();
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
internal void InitVars() {
this.columnProductID = base.Columns["ProductID"];
this.columnProductName = base.Columns["ProductName"];
this.columnSupplierID = base.Columns["SupplierID"];
this.columnCategoryID = base.Columns["CategoryID"];
this.columnQuantityPerUnit = base.Columns["QuantityPerUnit"];
this.columnUnitPrice = base.Columns["UnitPrice"];
this.columnUnitsInStock = base.Columns["UnitsInStock"];
this.columnUnitsOnOrder = base.Columns["UnitsOnOrder"];
this.columnReorderLevel = base.Columns["ReorderLevel"];
this.columnDiscontinued = base.Columns["Discontinued"];
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
private void InitClass() {
this.columnProductID = new global::System.Data.DataColumn("ProductID", typeof(int), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnProductID);
this.columnProductName = new global::System.Data.DataColumn("ProductName", typeof(string), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnProductName);
this.columnSupplierID = new global::System.Data.DataColumn("SupplierID", typeof(int), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnSupplierID);
this.columnCategoryID = new global::System.Data.DataColumn("CategoryID", typeof(int), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnCategoryID);
this.columnQuantityPerUnit = new global::System.Data.DataColumn("QuantityPerUnit", typeof(string), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnQuantityPerUnit);
this.columnUnitPrice = new global::System.Data.DataColumn("UnitPrice", typeof(decimal), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnUnitPrice);
this.columnUnitsInStock = new global::System.Data.DataColumn("UnitsInStock", typeof(short), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnUnitsInStock);
this.columnUnitsOnOrder = new global::System.Data.DataColumn("UnitsOnOrder", typeof(short), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnUnitsOnOrder);
this.columnReorderLevel = new global::System.Data.DataColumn("ReorderLevel", typeof(short), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnReorderLevel);
this.columnDiscontinued = new global::System.Data.DataColumn("Discontinued", typeof(bool), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnDiscontinued);
this.Constraints.Add(new global::System.Data.UniqueConstraint("Constraint1", new global::System.Data.DataColumn[] {
this.columnProductID}, true));
this.columnProductID.AutoIncrement = true;
this.columnProductID.AllowDBNull = false;
this.columnProductID.Unique = true;
this.columnProductName.MaxLength = 40;
this.columnQuantityPerUnit.MaxLength = 20;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public ProductsRow NewProductsRow() {
return ((ProductsRow)(this.NewRow()));
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected override global::System.Data.DataRow NewRowFromBuilder(global::System.Data.DataRowBuilder builder) {
return new ProductsRow(builder);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected override global::System.Type GetRowType() {
return typeof(ProductsRow);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected override void OnRowChanged(global::System.Data.DataRowChangeEventArgs e) {
base.OnRowChanged(e);
if ((this.ProductsRowChanged != null)) {
this.ProductsRowChanged(this, new ProductsRowChangeEvent(((ProductsRow)(e.Row)), e.Action));
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected override void OnRowChanging(global::System.Data.DataRowChangeEventArgs e) {
base.OnRowChanging(e);
if ((this.ProductsRowChanging != null)) {
this.ProductsRowChanging(this, new ProductsRowChangeEvent(((ProductsRow)(e.Row)), e.Action));
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected override void OnRowDeleted(global::System.Data.DataRowChangeEventArgs e) {
base.OnRowDeleted(e);
if ((this.ProductsRowDeleted != null)) {
this.ProductsRowDeleted(this, new ProductsRowChangeEvent(((ProductsRow)(e.Row)), e.Action));
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected override void OnRowDeleting(global::System.Data.DataRowChangeEventArgs e) {
base.OnRowDeleting(e);
if ((this.ProductsRowDeleting != null)) {
this.ProductsRowDeleting(this, new ProductsRowChangeEvent(((ProductsRow)(e.Row)), e.Action));
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void RemoveProductsRow(ProductsRow row) {
this.Rows.Remove(row);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static global::System.Xml.Schema.XmlSchemaComplexType GetTypedTableSchema(global::System.Xml.Schema.XmlSchemaSet xs) {
global::System.Xml.Schema.XmlSchemaComplexType type = new global::System.Xml.Schema.XmlSchemaComplexType();
global::System.Xml.Schema.XmlSchemaSequence sequence = new global::System.Xml.Schema.XmlSchemaSequence();
NorthwindDataSet ds = new NorthwindDataSet();
global::System.Xml.Schema.XmlSchemaAny any1 = new global::System.Xml.Schema.XmlSchemaAny();
any1.Namespace = "http://www.w3.org/2001/XMLSchema";
any1.MinOccurs = new decimal(0);
any1.MaxOccurs = decimal.MaxValue;
any1.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
sequence.Items.Add(any1);
global::System.Xml.Schema.XmlSchemaAny any2 = new global::System.Xml.Schema.XmlSchemaAny();
any2.Namespace = "urn:schemas-microsoft-com:xml-diffgram-v1";
any2.MinOccurs = new decimal(1);
any2.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
sequence.Items.Add(any2);
global::System.Xml.Schema.XmlSchemaAttribute attribute1 = new global::System.Xml.Schema.XmlSchemaAttribute();
attribute1.Name = "namespace";
attribute1.FixedValue = ds.Namespace;
type.Attributes.Add(attribute1);
global::System.Xml.Schema.XmlSchemaAttribute attribute2 = new global::System.Xml.Schema.XmlSchemaAttribute();
attribute2.Name = "tableTypeName";
attribute2.FixedValue = "ProductsDataTable";
type.Attributes.Add(attribute2);
type.Particle = sequence;
global::System.Xml.Schema.XmlSchema dsSchema = ds.GetSchemaSerializable();
if (xs.Contains(dsSchema.TargetNamespace)) {
global::System.IO.MemoryStream s1 = new global::System.IO.MemoryStream();
global::System.IO.MemoryStream s2 = new global::System.IO.MemoryStream();
try {
global::System.Xml.Schema.XmlSchema schema = null;
dsSchema.Write(s1);
for (global::System.Collections.IEnumerator schemas = xs.Schemas(dsSchema.TargetNamespace).GetEnumerator(); schemas.MoveNext(); ) {
schema = ((global::System.Xml.Schema.XmlSchema)(schemas.Current));
s2.SetLength(0);
schema.Write(s2);
if ((s1.Length == s2.Length)) {
s1.Position = 0;
s2.Position = 0;
for (; ((s1.Position != s1.Length)
&& (s1.ReadByte() == s2.ReadByte())); ) {
;
}
if ((s1.Position == s1.Length)) {
return type;
}
}
}
}
finally {
if ((s1 != null)) {
s1.Close();
}
if ((s2 != null)) {
s2.Close();
}
}
}
xs.Add(dsSchema);
return type;
}
}
/// <summary>
///Represents the strongly named DataTable class.
///</summary>
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "2.0.0.0")]
[global::System.Serializable()]
[global::System.Xml.Serialization.XmlSchemaProviderAttribute("GetTypedTableSchema")]
public partial class SuppliersDataTable : global::System.Data.DataTable, global::System.Collections.IEnumerable {
private global::System.Data.DataColumn columnSupplierID;
private global::System.Data.DataColumn columnCompanyName;
private global::System.Data.DataColumn columnContactName;
private global::System.Data.DataColumn columnContactTitle;
private global::System.Data.DataColumn columnAddress;
private global::System.Data.DataColumn columnCity;
private global::System.Data.DataColumn columnRegion;
private global::System.Data.DataColumn columnPostalCode;
private global::System.Data.DataColumn columnCountry;
private global::System.Data.DataColumn columnPhone;
private global::System.Data.DataColumn columnFax;
private global::System.Data.DataColumn columnHomePage;
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public SuppliersDataTable() {
this.TableName = "Suppliers";
this.BeginInit();
this.InitClass();
this.EndInit();
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
internal SuppliersDataTable(global::System.Data.DataTable table) {
this.TableName = 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;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected SuppliersDataTable(global::System.Runtime.Serialization.SerializationInfo info, global::System.Runtime.Serialization.StreamingContext context) :
base(info, context) {
this.InitVars();
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public global::System.Data.DataColumn SupplierIDColumn {
get {
return this.columnSupplierID;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public global::System.Data.DataColumn CompanyNameColumn {
get {
return this.columnCompanyName;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public global::System.Data.DataColumn ContactNameColumn {
get {
return this.columnContactName;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public global::System.Data.DataColumn ContactTitleColumn {
get {
return this.columnContactTitle;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public global::System.Data.DataColumn AddressColumn {
get {
return this.columnAddress;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public global::System.Data.DataColumn CityColumn {
get {
return this.columnCity;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public global::System.Data.DataColumn RegionColumn {
get {
return this.columnRegion;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public global::System.Data.DataColumn PostalCodeColumn {
get {
return this.columnPostalCode;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public global::System.Data.DataColumn CountryColumn {
get {
return this.columnCountry;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public global::System.Data.DataColumn PhoneColumn {
get {
return this.columnPhone;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public global::System.Data.DataColumn FaxColumn {
get {
return this.columnFax;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public global::System.Data.DataColumn HomePageColumn {
get {
return this.columnHomePage;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Browsable(false)]
public int Count {
get {
return this.Rows.Count;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public SuppliersRow this[int index] {
get {
return ((SuppliersRow)(this.Rows[index]));
}
}
public event SuppliersRowChangeEventHandler SuppliersRowChanging;
public event SuppliersRowChangeEventHandler SuppliersRowChanged;
public event SuppliersRowChangeEventHandler SuppliersRowDeleting;
public event SuppliersRowChangeEventHandler SuppliersRowDeleted;
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void AddSuppliersRow(SuppliersRow row) {
this.Rows.Add(row);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public SuppliersRow AddSuppliersRow(string CompanyName, string ContactName, string ContactTitle, string Address, string City, string Region, string PostalCode, string Country, string Phone, string Fax, string HomePage) {
SuppliersRow rowSuppliersRow = ((SuppliersRow)(this.NewRow()));
object[] columnValuesArray = new object[] {
null,
CompanyName,
ContactName,
ContactTitle,
Address,
City,
Region,
PostalCode,
Country,
Phone,
Fax,
HomePage};
rowSuppliersRow.ItemArray = columnValuesArray;
this.Rows.Add(rowSuppliersRow);
return rowSuppliersRow;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public SuppliersRow FindBySupplierID(int SupplierID) {
return ((SuppliersRow)(this.Rows.Find(new object[] {
SupplierID})));
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public virtual global::System.Collections.IEnumerator GetEnumerator() {
return this.Rows.GetEnumerator();
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public override global::System.Data.DataTable Clone() {
SuppliersDataTable cln = ((SuppliersDataTable)(base.Clone()));
cln.InitVars();
return cln;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected override global::System.Data.DataTable CreateInstance() {
return new SuppliersDataTable();
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
internal void InitVars() {
this.columnSupplierID = base.Columns["SupplierID"];
this.columnCompanyName = base.Columns["CompanyName"];
this.columnContactName = base.Columns["ContactName"];
this.columnContactTitle = base.Columns["ContactTitle"];
this.columnAddress = base.Columns["Address"];
this.columnCity = base.Columns["City"];
this.columnRegion = base.Columns["Region"];
this.columnPostalCode = base.Columns["PostalCode"];
this.columnCountry = base.Columns["Country"];
this.columnPhone = base.Columns["Phone"];
this.columnFax = base.Columns["Fax"];
this.columnHomePage = base.Columns["HomePage"];
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
private void InitClass() {
this.columnSupplierID = new global::System.Data.DataColumn("SupplierID", typeof(int), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnSupplierID);
this.columnCompanyName = new global::System.Data.DataColumn("CompanyName", typeof(string), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnCompanyName);
this.columnContactName = new global::System.Data.DataColumn("ContactName", typeof(string), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnContactName);
this.columnContactTitle = new global::System.Data.DataColumn("ContactTitle", typeof(string), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnContactTitle);
this.columnAddress = new global::System.Data.DataColumn("Address", typeof(string), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnAddress);
this.columnCity = new global::System.Data.DataColumn("City", typeof(string), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnCity);
this.columnRegion = new global::System.Data.DataColumn("Region", typeof(string), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnRegion);
this.columnPostalCode = new global::System.Data.DataColumn("PostalCode", typeof(string), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnPostalCode);
this.columnCountry = new global::System.Data.DataColumn("Country", typeof(string), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnCountry);
this.columnPhone = new global::System.Data.DataColumn("Phone", typeof(string), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnPhone);
this.columnFax = new global::System.Data.DataColumn("Fax", typeof(string), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnFax);
this.columnHomePage = new global::System.Data.DataColumn("HomePage", typeof(string), null, global::System.Data.MappingType.Element);
base.Columns.Add(this.columnHomePage);
this.Constraints.Add(new global::System.Data.UniqueConstraint("Constraint1", new global::System.Data.DataColumn[] {
this.columnSupplierID}, true));
this.columnSupplierID.AutoIncrement = true;
this.columnSupplierID.AllowDBNull = false;
this.columnSupplierID.Unique = true;
this.columnCompanyName.MaxLength = 40;
this.columnContactName.MaxLength = 30;
this.columnContactTitle.MaxLength = 30;
this.columnAddress.MaxLength = 60;
this.columnCity.MaxLength = 15;
this.columnRegion.MaxLength = 15;
this.columnPostalCode.MaxLength = 10;
this.columnCountry.MaxLength = 15;
this.columnPhone.MaxLength = 24;
this.columnFax.MaxLength = 24;
this.columnHomePage.MaxLength = 536870910;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public SuppliersRow NewSuppliersRow() {
return ((SuppliersRow)(this.NewRow()));
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected override global::System.Data.DataRow NewRowFromBuilder(global::System.Data.DataRowBuilder builder) {
return new SuppliersRow(builder);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected override global::System.Type GetRowType() {
return typeof(SuppliersRow);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected override void OnRowChanged(global::System.Data.DataRowChangeEventArgs e) {
base.OnRowChanged(e);
if ((this.SuppliersRowChanged != null)) {
this.SuppliersRowChanged(this, new SuppliersRowChangeEvent(((SuppliersRow)(e.Row)), e.Action));
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected override void OnRowChanging(global::System.Data.DataRowChangeEventArgs e) {
base.OnRowChanging(e);
if ((this.SuppliersRowChanging != null)) {
this.SuppliersRowChanging(this, new SuppliersRowChangeEvent(((SuppliersRow)(e.Row)), e.Action));
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected override void OnRowDeleted(global::System.Data.DataRowChangeEventArgs e) {
base.OnRowDeleted(e);
if ((this.SuppliersRowDeleted != null)) {
this.SuppliersRowDeleted(this, new SuppliersRowChangeEvent(((SuppliersRow)(e.Row)), e.Action));
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected override void OnRowDeleting(global::System.Data.DataRowChangeEventArgs e) {
base.OnRowDeleting(e);
if ((this.SuppliersRowDeleting != null)) {
this.SuppliersRowDeleting(this, new SuppliersRowChangeEvent(((SuppliersRow)(e.Row)), e.Action));
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void RemoveSuppliersRow(SuppliersRow row) {
this.Rows.Remove(row);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static global::System.Xml.Schema.XmlSchemaComplexType GetTypedTableSchema(global::System.Xml.Schema.XmlSchemaSet xs) {
global::System.Xml.Schema.XmlSchemaComplexType type = new global::System.Xml.Schema.XmlSchemaComplexType();
global::System.Xml.Schema.XmlSchemaSequence sequence = new global::System.Xml.Schema.XmlSchemaSequence();
NorthwindDataSet ds = new NorthwindDataSet();
global::System.Xml.Schema.XmlSchemaAny any1 = new global::System.Xml.Schema.XmlSchemaAny();
any1.Namespace = "http://www.w3.org/2001/XMLSchema";
any1.MinOccurs = new decimal(0);
any1.MaxOccurs = decimal.MaxValue;
any1.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
sequence.Items.Add(any1);
global::System.Xml.Schema.XmlSchemaAny any2 = new global::System.Xml.Schema.XmlSchemaAny();
any2.Namespace = "urn:schemas-microsoft-com:xml-diffgram-v1";
any2.MinOccurs = new decimal(1);
any2.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
sequence.Items.Add(any2);
global::System.Xml.Schema.XmlSchemaAttribute attribute1 = new global::System.Xml.Schema.XmlSchemaAttribute();
attribute1.Name = "namespace";
attribute1.FixedValue = ds.Namespace;
type.Attributes.Add(attribute1);
global::System.Xml.Schema.XmlSchemaAttribute attribute2 = new global::System.Xml.Schema.XmlSchemaAttribute();
attribute2.Name = "tableTypeName";
attribute2.FixedValue = "SuppliersDataTable";
type.Attributes.Add(attribute2);
type.Particle = sequence;
global::System.Xml.Schema.XmlSchema dsSchema = ds.GetSchemaSerializable();
if (xs.Contains(dsSchema.TargetNamespace)) {
global::System.IO.MemoryStream s1 = new global::System.IO.MemoryStream();
global::System.IO.MemoryStream s2 = new global::System.IO.MemoryStream();
try {
global::System.Xml.Schema.XmlSchema schema = null;
dsSchema.Write(s1);
for (global::System.Collections.IEnumerator schemas = xs.Schemas(dsSchema.TargetNamespace).GetEnumerator(); schemas.MoveNext(); ) {
schema = ((global::System.Xml.Schema.XmlSchema)(schemas.Current));
s2.SetLength(0);
schema.Write(s2);
if ((s1.Length == s2.Length)) {
s1.Position = 0;
s2.Position = 0;
for (; ((s1.Position != s1.Length)
&& (s1.ReadByte() == s2.ReadByte())); ) {
;
}
if ((s1.Position == s1.Length)) {
return type;
}
}
}
}
finally {
if ((s1 != null)) {
s1.Close();
}
if ((s2 != null)) {
s2.Close();
}
}
}
xs.Add(dsSchema);
return type;
}
}
/// <summary>
///Represents strongly named DataRow class.
///</summary>
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "2.0.0.0")]
public partial class CategoriesRow : global::System.Data.DataRow {
private CategoriesDataTable tableCategories;
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
internal CategoriesRow(global::System.Data.DataRowBuilder rb) :
base(rb) {
this.tableCategories = ((CategoriesDataTable)(this.Table));
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public int CategoryID {
get {
return ((int)(this[this.tableCategories.CategoryIDColumn]));
}
set {
this[this.tableCategories.CategoryIDColumn] = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public string CategoryName {
get {
try {
return ((string)(this[this.tableCategories.CategoryNameColumn]));
}
catch (global::System.InvalidCastException e) {
throw new global::System.Data.StrongTypingException("The value for column \'CategoryName\' in table \'Categories\' is DBNull.", e);
}
}
set {
this[this.tableCategories.CategoryNameColumn] = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public string Description {
get {
try {
return ((string)(this[this.tableCategories.DescriptionColumn]));
}
catch (global::System.InvalidCastException e) {
throw new global::System.Data.StrongTypingException("The value for column \'Description\' in table \'Categories\' is DBNull.", e);
}
}
set {
this[this.tableCategories.DescriptionColumn] = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public byte[] Picture {
get {
try {
return ((byte[])(this[this.tableCategories.PictureColumn]));
}
catch (global::System.InvalidCastException e) {
throw new global::System.Data.StrongTypingException("The value for column \'Picture\' in table \'Categories\' is DBNull.", e);
}
}
set {
this[this.tableCategories.PictureColumn] = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public bool IsCategoryNameNull() {
return this.IsNull(this.tableCategories.CategoryNameColumn);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void SetCategoryNameNull() {
this[this.tableCategories.CategoryNameColumn] = global::System.Convert.DBNull;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public bool IsDescriptionNull() {
return this.IsNull(this.tableCategories.DescriptionColumn);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void SetDescriptionNull() {
this[this.tableCategories.DescriptionColumn] = global::System.Convert.DBNull;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public bool IsPictureNull() {
return this.IsNull(this.tableCategories.PictureColumn);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void SetPictureNull() {
this[this.tableCategories.PictureColumn] = global::System.Convert.DBNull;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public ProductsRow[] GetProductsRows() {
if ((this.Table.ChildRelations["CategoriesProducts"] == null)) {
return new ProductsRow[0];
}
else {
return ((ProductsRow[])(base.GetChildRows(this.Table.ChildRelations["CategoriesProducts"])));
}
}
}
/// <summary>
///Represents strongly named DataRow class.
///</summary>
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "2.0.0.0")]
public partial class ProductsRow : global::System.Data.DataRow {
private ProductsDataTable tableProducts;
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
internal ProductsRow(global::System.Data.DataRowBuilder rb) :
base(rb) {
this.tableProducts = ((ProductsDataTable)(this.Table));
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public int ProductID {
get {
return ((int)(this[this.tableProducts.ProductIDColumn]));
}
set {
this[this.tableProducts.ProductIDColumn] = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public string ProductName {
get {
try {
return ((string)(this[this.tableProducts.ProductNameColumn]));
}
catch (global::System.InvalidCastException e) {
throw new global::System.Data.StrongTypingException("The value for column \'ProductName\' in table \'Products\' is DBNull.", e);
}
}
set {
this[this.tableProducts.ProductNameColumn] = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public int SupplierID {
get {
try {
return ((int)(this[this.tableProducts.SupplierIDColumn]));
}
catch (global::System.InvalidCastException e) {
throw new global::System.Data.StrongTypingException("The value for column \'SupplierID\' in table \'Products\' is DBNull.", e);
}
}
set {
this[this.tableProducts.SupplierIDColumn] = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public int CategoryID {
get {
try {
return ((int)(this[this.tableProducts.CategoryIDColumn]));
}
catch (global::System.InvalidCastException e) {
throw new global::System.Data.StrongTypingException("The value for column \'CategoryID\' in table \'Products\' is DBNull.", e);
}
}
set {
this[this.tableProducts.CategoryIDColumn] = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public string QuantityPerUnit {
get {
try {
return ((string)(this[this.tableProducts.QuantityPerUnitColumn]));
}
catch (global::System.InvalidCastException e) {
throw new global::System.Data.StrongTypingException("The value for column \'QuantityPerUnit\' in table \'Products\' is DBNull.", e);
}
}
set {
this[this.tableProducts.QuantityPerUnitColumn] = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public decimal UnitPrice {
get {
try {
return ((decimal)(this[this.tableProducts.UnitPriceColumn]));
}
catch (global::System.InvalidCastException e) {
throw new global::System.Data.StrongTypingException("The value for column \'UnitPrice\' in table \'Products\' is DBNull.", e);
}
}
set {
this[this.tableProducts.UnitPriceColumn] = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public short UnitsInStock {
get {
try {
return ((short)(this[this.tableProducts.UnitsInStockColumn]));
}
catch (global::System.InvalidCastException e) {
throw new global::System.Data.StrongTypingException("The value for column \'UnitsInStock\' in table \'Products\' is DBNull.", e);
}
}
set {
this[this.tableProducts.UnitsInStockColumn] = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public short UnitsOnOrder {
get {
try {
return ((short)(this[this.tableProducts.UnitsOnOrderColumn]));
}
catch (global::System.InvalidCastException e) {
throw new global::System.Data.StrongTypingException("The value for column \'UnitsOnOrder\' in table \'Products\' is DBNull.", e);
}
}
set {
this[this.tableProducts.UnitsOnOrderColumn] = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public short ReorderLevel {
get {
try {
return ((short)(this[this.tableProducts.ReorderLevelColumn]));
}
catch (global::System.InvalidCastException e) {
throw new global::System.Data.StrongTypingException("The value for column \'ReorderLevel\' in table \'Products\' is DBNull.", e);
}
}
set {
this[this.tableProducts.ReorderLevelColumn] = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public bool Discontinued {
get {
try {
return ((bool)(this[this.tableProducts.DiscontinuedColumn]));
}
catch (global::System.InvalidCastException e) {
throw new global::System.Data.StrongTypingException("The value for column \'Discontinued\' in table \'Products\' is DBNull.", e);
}
}
set {
this[this.tableProducts.DiscontinuedColumn] = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public CategoriesRow CategoriesRow {
get {
return ((CategoriesRow)(this.GetParentRow(this.Table.ParentRelations["CategoriesProducts"])));
}
set {
this.SetParentRow(value, this.Table.ParentRelations["CategoriesProducts"]);
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public SuppliersRow SuppliersRow {
get {
return ((SuppliersRow)(this.GetParentRow(this.Table.ParentRelations["SuppliersProducts"])));
}
set {
this.SetParentRow(value, this.Table.ParentRelations["SuppliersProducts"]);
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public bool IsProductNameNull() {
return this.IsNull(this.tableProducts.ProductNameColumn);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void SetProductNameNull() {
this[this.tableProducts.ProductNameColumn] = global::System.Convert.DBNull;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public bool IsSupplierIDNull() {
return this.IsNull(this.tableProducts.SupplierIDColumn);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void SetSupplierIDNull() {
this[this.tableProducts.SupplierIDColumn] = global::System.Convert.DBNull;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public bool IsCategoryIDNull() {
return this.IsNull(this.tableProducts.CategoryIDColumn);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void SetCategoryIDNull() {
this[this.tableProducts.CategoryIDColumn] = global::System.Convert.DBNull;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public bool IsQuantityPerUnitNull() {
return this.IsNull(this.tableProducts.QuantityPerUnitColumn);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void SetQuantityPerUnitNull() {
this[this.tableProducts.QuantityPerUnitColumn] = global::System.Convert.DBNull;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public bool IsUnitPriceNull() {
return this.IsNull(this.tableProducts.UnitPriceColumn);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void SetUnitPriceNull() {
this[this.tableProducts.UnitPriceColumn] = global::System.Convert.DBNull;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public bool IsUnitsInStockNull() {
return this.IsNull(this.tableProducts.UnitsInStockColumn);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void SetUnitsInStockNull() {
this[this.tableProducts.UnitsInStockColumn] = global::System.Convert.DBNull;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public bool IsUnitsOnOrderNull() {
return this.IsNull(this.tableProducts.UnitsOnOrderColumn);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void SetUnitsOnOrderNull() {
this[this.tableProducts.UnitsOnOrderColumn] = global::System.Convert.DBNull;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public bool IsReorderLevelNull() {
return this.IsNull(this.tableProducts.ReorderLevelColumn);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void SetReorderLevelNull() {
this[this.tableProducts.ReorderLevelColumn] = global::System.Convert.DBNull;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public bool IsDiscontinuedNull() {
return this.IsNull(this.tableProducts.DiscontinuedColumn);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void SetDiscontinuedNull() {
this[this.tableProducts.DiscontinuedColumn] = global::System.Convert.DBNull;
}
}
/// <summary>
///Represents strongly named DataRow class.
///</summary>
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "2.0.0.0")]
public partial class SuppliersRow : global::System.Data.DataRow {
private SuppliersDataTable tableSuppliers;
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
internal SuppliersRow(global::System.Data.DataRowBuilder rb) :
base(rb) {
this.tableSuppliers = ((SuppliersDataTable)(this.Table));
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public int SupplierID {
get {
return ((int)(this[this.tableSuppliers.SupplierIDColumn]));
}
set {
this[this.tableSuppliers.SupplierIDColumn] = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public string CompanyName {
get {
try {
return ((string)(this[this.tableSuppliers.CompanyNameColumn]));
}
catch (global::System.InvalidCastException e) {
throw new global::System.Data.StrongTypingException("The value for column \'CompanyName\' in table \'Suppliers\' is DBNull.", e);
}
}
set {
this[this.tableSuppliers.CompanyNameColumn] = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public string ContactName {
get {
try {
return ((string)(this[this.tableSuppliers.ContactNameColumn]));
}
catch (global::System.InvalidCastException e) {
throw new global::System.Data.StrongTypingException("The value for column \'ContactName\' in table \'Suppliers\' is DBNull.", e);
}
}
set {
this[this.tableSuppliers.ContactNameColumn] = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public string ContactTitle {
get {
try {
return ((string)(this[this.tableSuppliers.ContactTitleColumn]));
}
catch (global::System.InvalidCastException e) {
throw new global::System.Data.StrongTypingException("The value for column \'ContactTitle\' in table \'Suppliers\' is DBNull.", e);
}
}
set {
this[this.tableSuppliers.ContactTitleColumn] = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public string Address {
get {
try {
return ((string)(this[this.tableSuppliers.AddressColumn]));
}
catch (global::System.InvalidCastException e) {
throw new global::System.Data.StrongTypingException("The value for column \'Address\' in table \'Suppliers\' is DBNull.", e);
}
}
set {
this[this.tableSuppliers.AddressColumn] = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public string City {
get {
try {
return ((string)(this[this.tableSuppliers.CityColumn]));
}
catch (global::System.InvalidCastException e) {
throw new global::System.Data.StrongTypingException("The value for column \'City\' in table \'Suppliers\' is DBNull.", e);
}
}
set {
this[this.tableSuppliers.CityColumn] = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public string Region {
get {
try {
return ((string)(this[this.tableSuppliers.RegionColumn]));
}
catch (global::System.InvalidCastException e) {
throw new global::System.Data.StrongTypingException("The value for column \'Region\' in table \'Suppliers\' is DBNull.", e);
}
}
set {
this[this.tableSuppliers.RegionColumn] = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public string PostalCode {
get {
try {
return ((string)(this[this.tableSuppliers.PostalCodeColumn]));
}
catch (global::System.InvalidCastException e) {
throw new global::System.Data.StrongTypingException("The value for column \'PostalCode\' in table \'Suppliers\' is DBNull.", e);
}
}
set {
this[this.tableSuppliers.PostalCodeColumn] = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public string Country {
get {
try {
return ((string)(this[this.tableSuppliers.CountryColumn]));
}
catch (global::System.InvalidCastException e) {
throw new global::System.Data.StrongTypingException("The value for column \'Country\' in table \'Suppliers\' is DBNull.", e);
}
}
set {
this[this.tableSuppliers.CountryColumn] = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public string Phone {
get {
try {
return ((string)(this[this.tableSuppliers.PhoneColumn]));
}
catch (global::System.InvalidCastException e) {
throw new global::System.Data.StrongTypingException("The value for column \'Phone\' in table \'Suppliers\' is DBNull.", e);
}
}
set {
this[this.tableSuppliers.PhoneColumn] = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public string Fax {
get {
try {
return ((string)(this[this.tableSuppliers.FaxColumn]));
}
catch (global::System.InvalidCastException e) {
throw new global::System.Data.StrongTypingException("The value for column \'Fax\' in table \'Suppliers\' is DBNull.", e);
}
}
set {
this[this.tableSuppliers.FaxColumn] = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public string HomePage {
get {
try {
return ((string)(this[this.tableSuppliers.HomePageColumn]));
}
catch (global::System.InvalidCastException e) {
throw new global::System.Data.StrongTypingException("The value for column \'HomePage\' in table \'Suppliers\' is DBNull.", e);
}
}
set {
this[this.tableSuppliers.HomePageColumn] = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public bool IsCompanyNameNull() {
return this.IsNull(this.tableSuppliers.CompanyNameColumn);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void SetCompanyNameNull() {
this[this.tableSuppliers.CompanyNameColumn] = global::System.Convert.DBNull;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public bool IsContactNameNull() {
return this.IsNull(this.tableSuppliers.ContactNameColumn);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void SetContactNameNull() {
this[this.tableSuppliers.ContactNameColumn] = global::System.Convert.DBNull;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public bool IsContactTitleNull() {
return this.IsNull(this.tableSuppliers.ContactTitleColumn);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void SetContactTitleNull() {
this[this.tableSuppliers.ContactTitleColumn] = global::System.Convert.DBNull;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public bool IsAddressNull() {
return this.IsNull(this.tableSuppliers.AddressColumn);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void SetAddressNull() {
this[this.tableSuppliers.AddressColumn] = global::System.Convert.DBNull;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public bool IsCityNull() {
return this.IsNull(this.tableSuppliers.CityColumn);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void SetCityNull() {
this[this.tableSuppliers.CityColumn] = global::System.Convert.DBNull;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public bool IsRegionNull() {
return this.IsNull(this.tableSuppliers.RegionColumn);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void SetRegionNull() {
this[this.tableSuppliers.RegionColumn] = global::System.Convert.DBNull;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public bool IsPostalCodeNull() {
return this.IsNull(this.tableSuppliers.PostalCodeColumn);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void SetPostalCodeNull() {
this[this.tableSuppliers.PostalCodeColumn] = global::System.Convert.DBNull;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public bool IsCountryNull() {
return this.IsNull(this.tableSuppliers.CountryColumn);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void SetCountryNull() {
this[this.tableSuppliers.CountryColumn] = global::System.Convert.DBNull;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public bool IsPhoneNull() {
return this.IsNull(this.tableSuppliers.PhoneColumn);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void SetPhoneNull() {
this[this.tableSuppliers.PhoneColumn] = global::System.Convert.DBNull;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public bool IsFaxNull() {
return this.IsNull(this.tableSuppliers.FaxColumn);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void SetFaxNull() {
this[this.tableSuppliers.FaxColumn] = global::System.Convert.DBNull;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public bool IsHomePageNull() {
return this.IsNull(this.tableSuppliers.HomePageColumn);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public void SetHomePageNull() {
this[this.tableSuppliers.HomePageColumn] = global::System.Convert.DBNull;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public ProductsRow[] GetProductsRows() {
if ((this.Table.ChildRelations["SuppliersProducts"] == null)) {
return new ProductsRow[0];
}
else {
return ((ProductsRow[])(base.GetChildRows(this.Table.ChildRelations["SuppliersProducts"])));
}
}
}
/// <summary>
///Row event argument class
///</summary>
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "2.0.0.0")]
public class CategoriesRowChangeEvent : global::System.EventArgs {
private CategoriesRow eventRow;
private global::System.Data.DataRowAction eventAction;
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public CategoriesRowChangeEvent(CategoriesRow row, global::System.Data.DataRowAction action) {
this.eventRow = row;
this.eventAction = action;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public CategoriesRow Row {
get {
return this.eventRow;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public global::System.Data.DataRowAction Action {
get {
return this.eventAction;
}
}
}
/// <summary>
///Row event argument class
///</summary>
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "2.0.0.0")]
public class ProductsRowChangeEvent : global::System.EventArgs {
private ProductsRow eventRow;
private global::System.Data.DataRowAction eventAction;
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public ProductsRowChangeEvent(ProductsRow row, global::System.Data.DataRowAction action) {
this.eventRow = row;
this.eventAction = action;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public ProductsRow Row {
get {
return this.eventRow;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public global::System.Data.DataRowAction Action {
get {
return this.eventAction;
}
}
}
/// <summary>
///Row event argument class
///</summary>
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "2.0.0.0")]
public class SuppliersRowChangeEvent : global::System.EventArgs {
private SuppliersRow eventRow;
private global::System.Data.DataRowAction eventAction;
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public SuppliersRowChangeEvent(SuppliersRow row, global::System.Data.DataRowAction action) {
this.eventRow = row;
this.eventAction = action;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public SuppliersRow Row {
get {
return this.eventRow;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public global::System.Data.DataRowAction Action {
get {
return this.eventAction;
}
}
}
}
}
namespace ASPNET_MVC_Store.Model.NorthwindDataSetTableAdapters {
/// <summary>
///Represents the connection and commands used to retrieve and save data.
///</summary>
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "2.0.0.0")]
[global::System.ComponentModel.DesignerCategoryAttribute("code")]
[global::System.ComponentModel.ToolboxItem(true)]
[global::System.ComponentModel.DataObjectAttribute(true)]
[global::System.ComponentModel.DesignerAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterDesigner, Microsoft.VSDesigner" +
", Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
public partial class CategoriesTableAdapter : global::System.ComponentModel.Component {
private global::System.Data.OleDb.OleDbDataAdapter _adapter;
private global::System.Data.OleDb.OleDbConnection _connection;
private global::System.Data.OleDb.OleDbCommand[] _commandCollection;
private bool _clearBeforeFill;
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public CategoriesTableAdapter() {
this.ClearBeforeFill = true;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
private global::System.Data.OleDb.OleDbDataAdapter Adapter {
get {
if ((this._adapter == null)) {
this.InitAdapter();
}
return this._adapter;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
internal global::System.Data.OleDb.OleDbConnection Connection {
get {
if ((this._connection == null)) {
this.InitConnection();
}
return this._connection;
}
set {
this._connection = value;
if ((this.Adapter.InsertCommand != null)) {
this.Adapter.InsertCommand.Connection = value;
}
if ((this.Adapter.DeleteCommand != null)) {
this.Adapter.DeleteCommand.Connection = value;
}
if ((this.Adapter.UpdateCommand != null)) {
this.Adapter.UpdateCommand.Connection = value;
}
for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) {
if ((this.CommandCollection[i] != null)) {
((global::System.Data.OleDb.OleDbCommand)(this.CommandCollection[i])).Connection = value;
}
}
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected global::System.Data.OleDb.OleDbCommand[] CommandCollection {
get {
if ((this._commandCollection == null)) {
this.InitCommandCollection();
}
return this._commandCollection;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public bool ClearBeforeFill {
get {
return this._clearBeforeFill;
}
set {
this._clearBeforeFill = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
private void InitAdapter() {
this._adapter = new global::System.Data.OleDb.OleDbDataAdapter();
global::System.Data.Common.DataTableMapping tableMapping = new global::System.Data.Common.DataTableMapping();
tableMapping.SourceTable = "Table";
tableMapping.DataSetTable = "Categories";
tableMapping.ColumnMappings.Add("CategoryID", "CategoryID");
tableMapping.ColumnMappings.Add("CategoryName", "CategoryName");
tableMapping.ColumnMappings.Add("Description", "Description");
tableMapping.ColumnMappings.Add("Picture", "Picture");
this._adapter.TableMappings.Add(tableMapping);
this._adapter.DeleteCommand = new global::System.Data.OleDb.OleDbCommand();
this._adapter.DeleteCommand.Connection = this.Connection;
this._adapter.DeleteCommand.CommandText = "DELETE FROM `Categories` WHERE ((`CategoryID` = ?) AND ((? = 1 AND `CategoryName`" +
" IS NULL) OR (`CategoryName` = ?)))";
this._adapter.DeleteCommand.CommandType = global::System.Data.CommandType.Text;
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_CategoryID", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "CategoryID", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_CategoryName", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "CategoryName", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_CategoryName", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "CategoryName", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.InsertCommand = new global::System.Data.OleDb.OleDbCommand();
this._adapter.InsertCommand.Connection = this.Connection;
this._adapter.InsertCommand.CommandText = "INSERT INTO `Categories` (`CategoryName`, `Description`, `Picture`) VALUES (?, ?," +
" ?)";
this._adapter.InsertCommand.CommandType = global::System.Data.CommandType.Text;
this._adapter.InsertCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("CategoryName", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "CategoryName", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.InsertCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Description", global::System.Data.OleDb.OleDbType.LongVarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Description", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.InsertCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Picture", global::System.Data.OleDb.OleDbType.LongVarBinary, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Picture", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.UpdateCommand = new global::System.Data.OleDb.OleDbCommand();
this._adapter.UpdateCommand.Connection = this.Connection;
this._adapter.UpdateCommand.CommandText = "UPDATE `Categories` SET `CategoryName` = ?, `Description` = ?, `Picture` = ? WHER" +
"E ((`CategoryID` = ?) AND ((? = 1 AND `CategoryName` IS NULL) OR (`CategoryName`" +
" = ?)))";
this._adapter.UpdateCommand.CommandType = global::System.Data.CommandType.Text;
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("CategoryName", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "CategoryName", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Description", global::System.Data.OleDb.OleDbType.LongVarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Description", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Picture", global::System.Data.OleDb.OleDbType.LongVarBinary, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Picture", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_CategoryID", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "CategoryID", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_CategoryName", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "CategoryName", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_CategoryName", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "CategoryName", global::System.Data.DataRowVersion.Original, false, null));
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
private void InitConnection() {
this._connection = new global::System.Data.OleDb.OleDbConnection();
this._connection.ConnectionString = System.Configuration.ConfigurationManager.ConnectionStrings["NwindConnectionString"].ConnectionString;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
private void InitCommandCollection() {
this._commandCollection = new global::System.Data.OleDb.OleDbCommand[1];
this._commandCollection[0] = new global::System.Data.OleDb.OleDbCommand();
this._commandCollection[0].Connection = this.Connection;
this._commandCollection[0].CommandText = "SELECT CategoryID, CategoryName, Description, Picture FROM Categories";
this._commandCollection[0].CommandType = global::System.Data.CommandType.Text;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
[global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Fill, true)]
public virtual int Fill(NorthwindDataSet.CategoriesDataTable dataTable) {
this.Adapter.SelectCommand = this.CommandCollection[0];
if ((this.ClearBeforeFill == true)) {
dataTable.Clear();
}
int returnValue = this.Adapter.Fill(dataTable);
return returnValue;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
[global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, true)]
public virtual NorthwindDataSet.CategoriesDataTable GetData() {
this.Adapter.SelectCommand = this.CommandCollection[0];
NorthwindDataSet.CategoriesDataTable dataTable = new NorthwindDataSet.CategoriesDataTable();
this.Adapter.Fill(dataTable);
return dataTable;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
public virtual int Update(NorthwindDataSet.CategoriesDataTable dataTable) {
return this.Adapter.Update(dataTable);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
public virtual int Update(NorthwindDataSet dataSet) {
return this.Adapter.Update(dataSet, "Categories");
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
public virtual int Update(global::System.Data.DataRow dataRow) {
return this.Adapter.Update(new global::System.Data.DataRow[] {
dataRow});
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
public virtual int Update(global::System.Data.DataRow[] dataRows) {
return this.Adapter.Update(dataRows);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
[global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Delete, true)]
public virtual int Delete(int Original_CategoryID, string Original_CategoryName) {
this.Adapter.DeleteCommand.Parameters[0].Value = ((int)(Original_CategoryID));
if ((Original_CategoryName == null)) {
throw new global::System.ArgumentNullException("Original_CategoryName");
}
else {
this.Adapter.DeleteCommand.Parameters[1].Value = ((object)(0));
this.Adapter.DeleteCommand.Parameters[2].Value = ((string)(Original_CategoryName));
}
global::System.Data.ConnectionState previousConnectionState = this.Adapter.DeleteCommand.Connection.State;
if (((this.Adapter.DeleteCommand.Connection.State & global::System.Data.ConnectionState.Open)
!= global::System.Data.ConnectionState.Open)) {
this.Adapter.DeleteCommand.Connection.Open();
}
try {
int returnValue = this.Adapter.DeleteCommand.ExecuteNonQuery();
return returnValue;
}
finally {
if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
this.Adapter.DeleteCommand.Connection.Close();
}
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
[global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Insert, true)]
public virtual int Insert(string CategoryName, string Description, byte[] Picture) {
if ((CategoryName == null)) {
throw new global::System.ArgumentNullException("CategoryName");
}
else {
this.Adapter.InsertCommand.Parameters[0].Value = ((string)(CategoryName));
}
if ((Description == null)) {
this.Adapter.InsertCommand.Parameters[1].Value = global::System.DBNull.Value;
}
else {
this.Adapter.InsertCommand.Parameters[1].Value = ((string)(Description));
}
if ((Picture == null)) {
this.Adapter.InsertCommand.Parameters[2].Value = global::System.DBNull.Value;
}
else {
this.Adapter.InsertCommand.Parameters[2].Value = ((byte[])(Picture));
}
global::System.Data.ConnectionState previousConnectionState = this.Adapter.InsertCommand.Connection.State;
if (((this.Adapter.InsertCommand.Connection.State & global::System.Data.ConnectionState.Open)
!= global::System.Data.ConnectionState.Open)) {
this.Adapter.InsertCommand.Connection.Open();
}
try {
int returnValue = this.Adapter.InsertCommand.ExecuteNonQuery();
return returnValue;
}
finally {
if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
this.Adapter.InsertCommand.Connection.Close();
}
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
[global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, true)]
public virtual int Update(string CategoryName, string Description, byte[] Picture, int Original_CategoryID, string Original_CategoryName) {
if ((CategoryName == null)) {
throw new global::System.ArgumentNullException("CategoryName");
}
else {
this.Adapter.UpdateCommand.Parameters[0].Value = ((string)(CategoryName));
}
if ((Description == null)) {
this.Adapter.UpdateCommand.Parameters[1].Value = global::System.DBNull.Value;
}
else {
this.Adapter.UpdateCommand.Parameters[1].Value = ((string)(Description));
}
if ((Picture == null)) {
this.Adapter.UpdateCommand.Parameters[2].Value = global::System.DBNull.Value;
}
else {
this.Adapter.UpdateCommand.Parameters[2].Value = ((byte[])(Picture));
}
this.Adapter.UpdateCommand.Parameters[3].Value = ((int)(Original_CategoryID));
if ((Original_CategoryName == null)) {
throw new global::System.ArgumentNullException("Original_CategoryName");
}
else {
this.Adapter.UpdateCommand.Parameters[4].Value = ((object)(0));
this.Adapter.UpdateCommand.Parameters[5].Value = ((string)(Original_CategoryName));
}
global::System.Data.ConnectionState previousConnectionState = this.Adapter.UpdateCommand.Connection.State;
if (((this.Adapter.UpdateCommand.Connection.State & global::System.Data.ConnectionState.Open)
!= global::System.Data.ConnectionState.Open)) {
this.Adapter.UpdateCommand.Connection.Open();
}
try {
int returnValue = this.Adapter.UpdateCommand.ExecuteNonQuery();
return returnValue;
}
finally {
if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
this.Adapter.UpdateCommand.Connection.Close();
}
}
}
}
/// <summary>
///Represents the connection and commands used to retrieve and save data.
///</summary>
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "2.0.0.0")]
[global::System.ComponentModel.DesignerCategoryAttribute("code")]
[global::System.ComponentModel.ToolboxItem(true)]
[global::System.ComponentModel.DataObjectAttribute(true)]
[global::System.ComponentModel.DesignerAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterDesigner, Microsoft.VSDesigner" +
", Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
public partial class ProductsTableAdapter : global::System.ComponentModel.Component {
private global::System.Data.OleDb.OleDbDataAdapter _adapter;
private global::System.Data.OleDb.OleDbConnection _connection;
private global::System.Data.OleDb.OleDbCommand[] _commandCollection;
private bool _clearBeforeFill;
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public ProductsTableAdapter() {
this.ClearBeforeFill = true;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
private global::System.Data.OleDb.OleDbDataAdapter Adapter {
get {
if ((this._adapter == null)) {
this.InitAdapter();
}
return this._adapter;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
internal global::System.Data.OleDb.OleDbConnection Connection {
get {
if ((this._connection == null)) {
this.InitConnection();
}
return this._connection;
}
set {
this._connection = value;
if ((this.Adapter.InsertCommand != null)) {
this.Adapter.InsertCommand.Connection = value;
}
if ((this.Adapter.DeleteCommand != null)) {
this.Adapter.DeleteCommand.Connection = value;
}
if ((this.Adapter.UpdateCommand != null)) {
this.Adapter.UpdateCommand.Connection = value;
}
for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) {
if ((this.CommandCollection[i] != null)) {
((global::System.Data.OleDb.OleDbCommand)(this.CommandCollection[i])).Connection = value;
}
}
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected global::System.Data.OleDb.OleDbCommand[] CommandCollection {
get {
if ((this._commandCollection == null)) {
this.InitCommandCollection();
}
return this._commandCollection;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public bool ClearBeforeFill {
get {
return this._clearBeforeFill;
}
set {
this._clearBeforeFill = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
private void InitAdapter() {
this._adapter = new global::System.Data.OleDb.OleDbDataAdapter();
global::System.Data.Common.DataTableMapping tableMapping = new global::System.Data.Common.DataTableMapping();
tableMapping.SourceTable = "Table";
tableMapping.DataSetTable = "Products";
tableMapping.ColumnMappings.Add("ProductID", "ProductID");
tableMapping.ColumnMappings.Add("ProductName", "ProductName");
tableMapping.ColumnMappings.Add("SupplierID", "SupplierID");
tableMapping.ColumnMappings.Add("CategoryID", "CategoryID");
tableMapping.ColumnMappings.Add("QuantityPerUnit", "QuantityPerUnit");
tableMapping.ColumnMappings.Add("UnitPrice", "UnitPrice");
tableMapping.ColumnMappings.Add("UnitsInStock", "UnitsInStock");
tableMapping.ColumnMappings.Add("UnitsOnOrder", "UnitsOnOrder");
tableMapping.ColumnMappings.Add("ReorderLevel", "ReorderLevel");
tableMapping.ColumnMappings.Add("Discontinued", "Discontinued");
this._adapter.TableMappings.Add(tableMapping);
this._adapter.DeleteCommand = new global::System.Data.OleDb.OleDbCommand();
this._adapter.DeleteCommand.Connection = this.Connection;
this._adapter.DeleteCommand.CommandText = @"DELETE FROM `Products` WHERE ((`ProductID` = ?) AND ((? = 1 AND `ProductName` IS NULL) OR (`ProductName` = ?)) AND ((? = 1 AND `SupplierID` IS NULL) OR (`SupplierID` = ?)) AND ((? = 1 AND `CategoryID` IS NULL) OR (`CategoryID` = ?)) AND ((? = 1 AND `QuantityPerUnit` IS NULL) OR (`QuantityPerUnit` = ?)) AND ((? = 1 AND `UnitPrice` IS NULL) OR (`UnitPrice` = ?)) AND ((? = 1 AND `UnitsInStock` IS NULL) OR (`UnitsInStock` = ?)) AND ((? = 1 AND `UnitsOnOrder` IS NULL) OR (`UnitsOnOrder` = ?)) AND ((? = 1 AND `ReorderLevel` IS NULL) OR (`ReorderLevel` = ?)) AND ((? = 1 AND `Discontinued` IS NULL) OR (`Discontinued` = ?)))";
this._adapter.DeleteCommand.CommandType = global::System.Data.CommandType.Text;
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_ProductID", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ProductID", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_ProductName", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ProductName", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_ProductName", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ProductName", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_SupplierID", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "SupplierID", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_SupplierID", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "SupplierID", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_CategoryID", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "CategoryID", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_CategoryID", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "CategoryID", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_QuantityPerUnit", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "QuantityPerUnit", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_QuantityPerUnit", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "QuantityPerUnit", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_UnitPrice", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "UnitPrice", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_UnitPrice", global::System.Data.OleDb.OleDbType.Currency, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "UnitPrice", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_UnitsInStock", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "UnitsInStock", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_UnitsInStock", global::System.Data.OleDb.OleDbType.SmallInt, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "UnitsInStock", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_UnitsOnOrder", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "UnitsOnOrder", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_UnitsOnOrder", global::System.Data.OleDb.OleDbType.SmallInt, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "UnitsOnOrder", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_ReorderLevel", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ReorderLevel", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_ReorderLevel", global::System.Data.OleDb.OleDbType.SmallInt, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ReorderLevel", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_Discontinued", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Discontinued", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_Discontinued", global::System.Data.OleDb.OleDbType.Boolean, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Discontinued", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.InsertCommand = new global::System.Data.OleDb.OleDbCommand();
this._adapter.InsertCommand.Connection = this.Connection;
this._adapter.InsertCommand.CommandText = "INSERT INTO `Products` (`ProductName`, `SupplierID`, `CategoryID`, `QuantityPerUn" +
"it`, `UnitPrice`, `UnitsInStock`, `UnitsOnOrder`, `ReorderLevel`, `Discontinued`" +
") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?)";
this._adapter.InsertCommand.CommandType = global::System.Data.CommandType.Text;
this._adapter.InsertCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("ProductName", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ProductName", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.InsertCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("SupplierID", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "SupplierID", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.InsertCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("CategoryID", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "CategoryID", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.InsertCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("QuantityPerUnit", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "QuantityPerUnit", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.InsertCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("UnitPrice", global::System.Data.OleDb.OleDbType.Currency, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "UnitPrice", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.InsertCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("UnitsInStock", global::System.Data.OleDb.OleDbType.SmallInt, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "UnitsInStock", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.InsertCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("UnitsOnOrder", global::System.Data.OleDb.OleDbType.SmallInt, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "UnitsOnOrder", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.InsertCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("ReorderLevel", global::System.Data.OleDb.OleDbType.SmallInt, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ReorderLevel", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.InsertCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Discontinued", global::System.Data.OleDb.OleDbType.Boolean, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Discontinued", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.UpdateCommand = new global::System.Data.OleDb.OleDbCommand();
this._adapter.UpdateCommand.Connection = this.Connection;
this._adapter.UpdateCommand.CommandText = @"UPDATE `Products` SET `ProductName` = ?, `SupplierID` = ?, `CategoryID` = ?, `QuantityPerUnit` = ?, `UnitPrice` = ?, `UnitsInStock` = ?, `UnitsOnOrder` = ?, `ReorderLevel` = ?, `Discontinued` = ? WHERE ((`ProductID` = ?) AND ((? = 1 AND `ProductName` IS NULL) OR (`ProductName` = ?)) AND ((? = 1 AND `SupplierID` IS NULL) OR (`SupplierID` = ?)) AND ((? = 1 AND `CategoryID` IS NULL) OR (`CategoryID` = ?)) AND ((? = 1 AND `QuantityPerUnit` IS NULL) OR (`QuantityPerUnit` = ?)) AND ((? = 1 AND `UnitPrice` IS NULL) OR (`UnitPrice` = ?)) AND ((? = 1 AND `UnitsInStock` IS NULL) OR (`UnitsInStock` = ?)) AND ((? = 1 AND `UnitsOnOrder` IS NULL) OR (`UnitsOnOrder` = ?)) AND ((? = 1 AND `ReorderLevel` IS NULL) OR (`ReorderLevel` = ?)) AND ((? = 1 AND `Discontinued` IS NULL) OR (`Discontinued` = ?)))";
this._adapter.UpdateCommand.CommandType = global::System.Data.CommandType.Text;
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("ProductName", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ProductName", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("SupplierID", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "SupplierID", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("CategoryID", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "CategoryID", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("QuantityPerUnit", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "QuantityPerUnit", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("UnitPrice", global::System.Data.OleDb.OleDbType.Currency, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "UnitPrice", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("UnitsInStock", global::System.Data.OleDb.OleDbType.SmallInt, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "UnitsInStock", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("UnitsOnOrder", global::System.Data.OleDb.OleDbType.SmallInt, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "UnitsOnOrder", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("ReorderLevel", global::System.Data.OleDb.OleDbType.SmallInt, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ReorderLevel", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Discontinued", global::System.Data.OleDb.OleDbType.Boolean, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Discontinued", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_ProductID", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ProductID", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_ProductName", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ProductName", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_ProductName", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ProductName", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_SupplierID", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "SupplierID", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_SupplierID", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "SupplierID", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_CategoryID", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "CategoryID", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_CategoryID", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "CategoryID", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_QuantityPerUnit", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "QuantityPerUnit", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_QuantityPerUnit", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "QuantityPerUnit", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_UnitPrice", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "UnitPrice", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_UnitPrice", global::System.Data.OleDb.OleDbType.Currency, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "UnitPrice", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_UnitsInStock", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "UnitsInStock", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_UnitsInStock", global::System.Data.OleDb.OleDbType.SmallInt, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "UnitsInStock", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_UnitsOnOrder", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "UnitsOnOrder", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_UnitsOnOrder", global::System.Data.OleDb.OleDbType.SmallInt, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "UnitsOnOrder", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_ReorderLevel", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ReorderLevel", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_ReorderLevel", global::System.Data.OleDb.OleDbType.SmallInt, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ReorderLevel", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_Discontinued", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Discontinued", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_Discontinued", global::System.Data.OleDb.OleDbType.Boolean, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Discontinued", global::System.Data.DataRowVersion.Original, false, null));
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
private void InitConnection() {
this._connection = new global::System.Data.OleDb.OleDbConnection();
this._connection.ConnectionString = System.Configuration.ConfigurationManager.ConnectionStrings["NwindConnectionString"].ConnectionString;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
private void InitCommandCollection() {
this._commandCollection = new global::System.Data.OleDb.OleDbCommand[1];
this._commandCollection[0] = new global::System.Data.OleDb.OleDbCommand();
this._commandCollection[0].Connection = this.Connection;
this._commandCollection[0].CommandText = "SELECT ProductID, ProductName, SupplierID, CategoryID, QuantityPerUnit, UnitPrice" +
", UnitsInStock, UnitsOnOrder, ReorderLevel, Discontinued FROM Products";
this._commandCollection[0].CommandType = global::System.Data.CommandType.Text;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
[global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Fill, true)]
public virtual int Fill(NorthwindDataSet.ProductsDataTable dataTable) {
this.Adapter.SelectCommand = this.CommandCollection[0];
if ((this.ClearBeforeFill == true)) {
dataTable.Clear();
}
int returnValue = this.Adapter.Fill(dataTable);
return returnValue;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
[global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, true)]
public virtual NorthwindDataSet.ProductsDataTable GetData() {
this.Adapter.SelectCommand = this.CommandCollection[0];
NorthwindDataSet.ProductsDataTable dataTable = new NorthwindDataSet.ProductsDataTable();
this.Adapter.Fill(dataTable);
return dataTable;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
public virtual int Update(NorthwindDataSet.ProductsDataTable dataTable) {
return this.Adapter.Update(dataTable);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
public virtual int Update(NorthwindDataSet dataSet) {
return this.Adapter.Update(dataSet, "Products");
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
public virtual int Update(global::System.Data.DataRow dataRow) {
return this.Adapter.Update(new global::System.Data.DataRow[] {
dataRow});
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
public virtual int Update(global::System.Data.DataRow[] dataRows) {
return this.Adapter.Update(dataRows);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
[global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Delete, true)]
public virtual int Delete(int Original_ProductID, string Original_ProductName, global::System.Nullable<int> Original_SupplierID, global::System.Nullable<int> Original_CategoryID, string Original_QuantityPerUnit, global::System.Nullable<decimal> Original_UnitPrice, global::System.Nullable<short> Original_UnitsInStock, global::System.Nullable<short> Original_UnitsOnOrder, global::System.Nullable<short> Original_ReorderLevel, bool Original_Discontinued) {
this.Adapter.DeleteCommand.Parameters[0].Value = ((int)(Original_ProductID));
if ((Original_ProductName == null)) {
throw new global::System.ArgumentNullException("Original_ProductName");
}
else {
this.Adapter.DeleteCommand.Parameters[1].Value = ((object)(0));
this.Adapter.DeleteCommand.Parameters[2].Value = ((string)(Original_ProductName));
}
if ((Original_SupplierID.HasValue == true)) {
this.Adapter.DeleteCommand.Parameters[3].Value = ((object)(0));
this.Adapter.DeleteCommand.Parameters[4].Value = ((int)(Original_SupplierID.Value));
}
else {
this.Adapter.DeleteCommand.Parameters[3].Value = ((object)(1));
this.Adapter.DeleteCommand.Parameters[4].Value = global::System.DBNull.Value;
}
if ((Original_CategoryID.HasValue == true)) {
this.Adapter.DeleteCommand.Parameters[5].Value = ((object)(0));
this.Adapter.DeleteCommand.Parameters[6].Value = ((int)(Original_CategoryID.Value));
}
else {
this.Adapter.DeleteCommand.Parameters[5].Value = ((object)(1));
this.Adapter.DeleteCommand.Parameters[6].Value = global::System.DBNull.Value;
}
if ((Original_QuantityPerUnit == null)) {
this.Adapter.DeleteCommand.Parameters[7].Value = ((object)(1));
this.Adapter.DeleteCommand.Parameters[8].Value = global::System.DBNull.Value;
}
else {
this.Adapter.DeleteCommand.Parameters[7].Value = ((object)(0));
this.Adapter.DeleteCommand.Parameters[8].Value = ((string)(Original_QuantityPerUnit));
}
if ((Original_UnitPrice.HasValue == true)) {
this.Adapter.DeleteCommand.Parameters[9].Value = ((object)(0));
this.Adapter.DeleteCommand.Parameters[10].Value = ((decimal)(Original_UnitPrice.Value));
}
else {
this.Adapter.DeleteCommand.Parameters[9].Value = ((object)(1));
this.Adapter.DeleteCommand.Parameters[10].Value = global::System.DBNull.Value;
}
if ((Original_UnitsInStock.HasValue == true)) {
this.Adapter.DeleteCommand.Parameters[11].Value = ((object)(0));
this.Adapter.DeleteCommand.Parameters[12].Value = ((short)(Original_UnitsInStock.Value));
}
else {
this.Adapter.DeleteCommand.Parameters[11].Value = ((object)(1));
this.Adapter.DeleteCommand.Parameters[12].Value = global::System.DBNull.Value;
}
if ((Original_UnitsOnOrder.HasValue == true)) {
this.Adapter.DeleteCommand.Parameters[13].Value = ((object)(0));
this.Adapter.DeleteCommand.Parameters[14].Value = ((short)(Original_UnitsOnOrder.Value));
}
else {
this.Adapter.DeleteCommand.Parameters[13].Value = ((object)(1));
this.Adapter.DeleteCommand.Parameters[14].Value = global::System.DBNull.Value;
}
if ((Original_ReorderLevel.HasValue == true)) {
this.Adapter.DeleteCommand.Parameters[15].Value = ((object)(0));
this.Adapter.DeleteCommand.Parameters[16].Value = ((short)(Original_ReorderLevel.Value));
}
else {
this.Adapter.DeleteCommand.Parameters[15].Value = ((object)(1));
this.Adapter.DeleteCommand.Parameters[16].Value = global::System.DBNull.Value;
}
this.Adapter.DeleteCommand.Parameters[17].Value = ((object)(0));
this.Adapter.DeleteCommand.Parameters[18].Value = ((bool)(Original_Discontinued));
global::System.Data.ConnectionState previousConnectionState = this.Adapter.DeleteCommand.Connection.State;
if (((this.Adapter.DeleteCommand.Connection.State & global::System.Data.ConnectionState.Open)
!= global::System.Data.ConnectionState.Open)) {
this.Adapter.DeleteCommand.Connection.Open();
}
try {
int returnValue = this.Adapter.DeleteCommand.ExecuteNonQuery();
return returnValue;
}
finally {
if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
this.Adapter.DeleteCommand.Connection.Close();
}
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
[global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Insert, true)]
public virtual int Insert(string ProductName, global::System.Nullable<int> SupplierID, global::System.Nullable<int> CategoryID, string QuantityPerUnit, global::System.Nullable<decimal> UnitPrice, global::System.Nullable<short> UnitsInStock, global::System.Nullable<short> UnitsOnOrder, global::System.Nullable<short> ReorderLevel, bool Discontinued) {
if ((ProductName == null)) {
throw new global::System.ArgumentNullException("ProductName");
}
else {
this.Adapter.InsertCommand.Parameters[0].Value = ((string)(ProductName));
}
if ((SupplierID.HasValue == true)) {
this.Adapter.InsertCommand.Parameters[1].Value = ((int)(SupplierID.Value));
}
else {
this.Adapter.InsertCommand.Parameters[1].Value = global::System.DBNull.Value;
}
if ((CategoryID.HasValue == true)) {
this.Adapter.InsertCommand.Parameters[2].Value = ((int)(CategoryID.Value));
}
else {
this.Adapter.InsertCommand.Parameters[2].Value = global::System.DBNull.Value;
}
if ((QuantityPerUnit == null)) {
this.Adapter.InsertCommand.Parameters[3].Value = global::System.DBNull.Value;
}
else {
this.Adapter.InsertCommand.Parameters[3].Value = ((string)(QuantityPerUnit));
}
if ((UnitPrice.HasValue == true)) {
this.Adapter.InsertCommand.Parameters[4].Value = ((decimal)(UnitPrice.Value));
}
else {
this.Adapter.InsertCommand.Parameters[4].Value = global::System.DBNull.Value;
}
if ((UnitsInStock.HasValue == true)) {
this.Adapter.InsertCommand.Parameters[5].Value = ((short)(UnitsInStock.Value));
}
else {
this.Adapter.InsertCommand.Parameters[5].Value = global::System.DBNull.Value;
}
if ((UnitsOnOrder.HasValue == true)) {
this.Adapter.InsertCommand.Parameters[6].Value = ((short)(UnitsOnOrder.Value));
}
else {
this.Adapter.InsertCommand.Parameters[6].Value = global::System.DBNull.Value;
}
if ((ReorderLevel.HasValue == true)) {
this.Adapter.InsertCommand.Parameters[7].Value = ((short)(ReorderLevel.Value));
}
else {
this.Adapter.InsertCommand.Parameters[7].Value = global::System.DBNull.Value;
}
this.Adapter.InsertCommand.Parameters[8].Value = ((bool)(Discontinued));
global::System.Data.ConnectionState previousConnectionState = this.Adapter.InsertCommand.Connection.State;
if (((this.Adapter.InsertCommand.Connection.State & global::System.Data.ConnectionState.Open)
!= global::System.Data.ConnectionState.Open)) {
this.Adapter.InsertCommand.Connection.Open();
}
try {
int returnValue = this.Adapter.InsertCommand.ExecuteNonQuery();
return returnValue;
}
finally {
if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
this.Adapter.InsertCommand.Connection.Close();
}
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
[global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, true)]
public virtual int Update(
string ProductName,
global::System.Nullable<int> SupplierID,
global::System.Nullable<int> CategoryID,
string QuantityPerUnit,
global::System.Nullable<decimal> UnitPrice,
global::System.Nullable<short> UnitsInStock,
global::System.Nullable<short> UnitsOnOrder,
global::System.Nullable<short> ReorderLevel,
bool Discontinued,
int Original_ProductID,
string Original_ProductName,
global::System.Nullable<int> Original_SupplierID,
global::System.Nullable<int> Original_CategoryID,
string Original_QuantityPerUnit,
global::System.Nullable<decimal> Original_UnitPrice,
global::System.Nullable<short> Original_UnitsInStock,
global::System.Nullable<short> Original_UnitsOnOrder,
global::System.Nullable<short> Original_ReorderLevel,
bool Original_Discontinued) {
if ((ProductName == null)) {
throw new global::System.ArgumentNullException("ProductName");
}
else {
this.Adapter.UpdateCommand.Parameters[0].Value = ((string)(ProductName));
}
if ((SupplierID.HasValue == true)) {
this.Adapter.UpdateCommand.Parameters[1].Value = ((int)(SupplierID.Value));
}
else {
this.Adapter.UpdateCommand.Parameters[1].Value = global::System.DBNull.Value;
}
if ((CategoryID.HasValue == true)) {
this.Adapter.UpdateCommand.Parameters[2].Value = ((int)(CategoryID.Value));
}
else {
this.Adapter.UpdateCommand.Parameters[2].Value = global::System.DBNull.Value;
}
if ((QuantityPerUnit == null)) {
this.Adapter.UpdateCommand.Parameters[3].Value = global::System.DBNull.Value;
}
else {
this.Adapter.UpdateCommand.Parameters[3].Value = ((string)(QuantityPerUnit));
}
if ((UnitPrice.HasValue == true)) {
this.Adapter.UpdateCommand.Parameters[4].Value = ((decimal)(UnitPrice.Value));
}
else {
this.Adapter.UpdateCommand.Parameters[4].Value = global::System.DBNull.Value;
}
if ((UnitsInStock.HasValue == true)) {
this.Adapter.UpdateCommand.Parameters[5].Value = ((short)(UnitsInStock.Value));
}
else {
this.Adapter.UpdateCommand.Parameters[5].Value = global::System.DBNull.Value;
}
if ((UnitsOnOrder.HasValue == true)) {
this.Adapter.UpdateCommand.Parameters[6].Value = ((short)(UnitsOnOrder.Value));
}
else {
this.Adapter.UpdateCommand.Parameters[6].Value = global::System.DBNull.Value;
}
if ((ReorderLevel.HasValue == true)) {
this.Adapter.UpdateCommand.Parameters[7].Value = ((short)(ReorderLevel.Value));
}
else {
this.Adapter.UpdateCommand.Parameters[7].Value = global::System.DBNull.Value;
}
this.Adapter.UpdateCommand.Parameters[8].Value = ((bool)(Discontinued));
this.Adapter.UpdateCommand.Parameters[9].Value = ((int)(Original_ProductID));
if ((Original_ProductName == null)) {
throw new global::System.ArgumentNullException("Original_ProductName");
}
else {
this.Adapter.UpdateCommand.Parameters[10].Value = ((object)(0));
this.Adapter.UpdateCommand.Parameters[11].Value = ((string)(Original_ProductName));
}
if ((Original_SupplierID.HasValue == true)) {
this.Adapter.UpdateCommand.Parameters[12].Value = ((object)(0));
this.Adapter.UpdateCommand.Parameters[13].Value = ((int)(Original_SupplierID.Value));
}
else {
this.Adapter.UpdateCommand.Parameters[12].Value = ((object)(1));
this.Adapter.UpdateCommand.Parameters[13].Value = global::System.DBNull.Value;
}
if ((Original_CategoryID.HasValue == true)) {
this.Adapter.UpdateCommand.Parameters[14].Value = ((object)(0));
this.Adapter.UpdateCommand.Parameters[15].Value = ((int)(Original_CategoryID.Value));
}
else {
this.Adapter.UpdateCommand.Parameters[14].Value = ((object)(1));
this.Adapter.UpdateCommand.Parameters[15].Value = global::System.DBNull.Value;
}
if ((Original_QuantityPerUnit == null)) {
this.Adapter.UpdateCommand.Parameters[16].Value = ((object)(1));
this.Adapter.UpdateCommand.Parameters[17].Value = global::System.DBNull.Value;
}
else {
this.Adapter.UpdateCommand.Parameters[16].Value = ((object)(0));
this.Adapter.UpdateCommand.Parameters[17].Value = ((string)(Original_QuantityPerUnit));
}
if ((Original_UnitPrice.HasValue == true)) {
this.Adapter.UpdateCommand.Parameters[18].Value = ((object)(0));
this.Adapter.UpdateCommand.Parameters[19].Value = ((decimal)(Original_UnitPrice.Value));
}
else {
this.Adapter.UpdateCommand.Parameters[18].Value = ((object)(1));
this.Adapter.UpdateCommand.Parameters[19].Value = global::System.DBNull.Value;
}
if ((Original_UnitsInStock.HasValue == true)) {
this.Adapter.UpdateCommand.Parameters[20].Value = ((object)(0));
this.Adapter.UpdateCommand.Parameters[21].Value = ((short)(Original_UnitsInStock.Value));
}
else {
this.Adapter.UpdateCommand.Parameters[20].Value = ((object)(1));
this.Adapter.UpdateCommand.Parameters[21].Value = global::System.DBNull.Value;
}
if ((Original_UnitsOnOrder.HasValue == true)) {
this.Adapter.UpdateCommand.Parameters[22].Value = ((object)(0));
this.Adapter.UpdateCommand.Parameters[23].Value = ((short)(Original_UnitsOnOrder.Value));
}
else {
this.Adapter.UpdateCommand.Parameters[22].Value = ((object)(1));
this.Adapter.UpdateCommand.Parameters[23].Value = global::System.DBNull.Value;
}
if ((Original_ReorderLevel.HasValue == true)) {
this.Adapter.UpdateCommand.Parameters[24].Value = ((object)(0));
this.Adapter.UpdateCommand.Parameters[25].Value = ((short)(Original_ReorderLevel.Value));
}
else {
this.Adapter.UpdateCommand.Parameters[24].Value = ((object)(1));
this.Adapter.UpdateCommand.Parameters[25].Value = global::System.DBNull.Value;
}
this.Adapter.UpdateCommand.Parameters[26].Value = ((object)(0));
this.Adapter.UpdateCommand.Parameters[27].Value = ((bool)(Original_Discontinued));
global::System.Data.ConnectionState previousConnectionState = this.Adapter.UpdateCommand.Connection.State;
if (((this.Adapter.UpdateCommand.Connection.State & global::System.Data.ConnectionState.Open)
!= global::System.Data.ConnectionState.Open)) {
this.Adapter.UpdateCommand.Connection.Open();
}
try {
int returnValue = this.Adapter.UpdateCommand.ExecuteNonQuery();
return returnValue;
}
finally {
if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
this.Adapter.UpdateCommand.Connection.Close();
}
}
}
}
/// <summary>
///Represents the connection and commands used to retrieve and save data.
///</summary>
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "2.0.0.0")]
[global::System.ComponentModel.DesignerCategoryAttribute("code")]
[global::System.ComponentModel.ToolboxItem(true)]
[global::System.ComponentModel.DataObjectAttribute(true)]
[global::System.ComponentModel.DesignerAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterDesigner, Microsoft.VSDesigner" +
", Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
public partial class SuppliersTableAdapter : global::System.ComponentModel.Component {
private global::System.Data.OleDb.OleDbDataAdapter _adapter;
private global::System.Data.OleDb.OleDbConnection _connection;
private global::System.Data.OleDb.OleDbCommand[] _commandCollection;
private bool _clearBeforeFill;
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public SuppliersTableAdapter() {
this.ClearBeforeFill = true;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
private global::System.Data.OleDb.OleDbDataAdapter Adapter {
get {
if ((this._adapter == null)) {
this.InitAdapter();
}
return this._adapter;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
internal global::System.Data.OleDb.OleDbConnection Connection {
get {
if ((this._connection == null)) {
this.InitConnection();
}
return this._connection;
}
set {
this._connection = value;
if ((this.Adapter.InsertCommand != null)) {
this.Adapter.InsertCommand.Connection = value;
}
if ((this.Adapter.DeleteCommand != null)) {
this.Adapter.DeleteCommand.Connection = value;
}
if ((this.Adapter.UpdateCommand != null)) {
this.Adapter.UpdateCommand.Connection = value;
}
for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) {
if ((this.CommandCollection[i] != null)) {
((global::System.Data.OleDb.OleDbCommand)(this.CommandCollection[i])).Connection = value;
}
}
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
protected global::System.Data.OleDb.OleDbCommand[] CommandCollection {
get {
if ((this._commandCollection == null)) {
this.InitCommandCollection();
}
return this._commandCollection;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public bool ClearBeforeFill {
get {
return this._clearBeforeFill;
}
set {
this._clearBeforeFill = value;
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
private void InitAdapter() {
this._adapter = new global::System.Data.OleDb.OleDbDataAdapter();
global::System.Data.Common.DataTableMapping tableMapping = new global::System.Data.Common.DataTableMapping();
tableMapping.SourceTable = "Table";
tableMapping.DataSetTable = "Suppliers";
tableMapping.ColumnMappings.Add("SupplierID", "SupplierID");
tableMapping.ColumnMappings.Add("CompanyName", "CompanyName");
tableMapping.ColumnMappings.Add("ContactName", "ContactName");
tableMapping.ColumnMappings.Add("ContactTitle", "ContactTitle");
tableMapping.ColumnMappings.Add("Address", "Address");
tableMapping.ColumnMappings.Add("City", "City");
tableMapping.ColumnMappings.Add("Region", "Region");
tableMapping.ColumnMappings.Add("PostalCode", "PostalCode");
tableMapping.ColumnMappings.Add("Country", "Country");
tableMapping.ColumnMappings.Add("Phone", "Phone");
tableMapping.ColumnMappings.Add("Fax", "Fax");
tableMapping.ColumnMappings.Add("HomePage", "HomePage");
this._adapter.TableMappings.Add(tableMapping);
this._adapter.DeleteCommand = new global::System.Data.OleDb.OleDbCommand();
this._adapter.DeleteCommand.Connection = this.Connection;
this._adapter.DeleteCommand.CommandText = @"DELETE FROM `Suppliers` WHERE ((`SupplierID` = ?) AND ((? = 1 AND `CompanyName` IS NULL) OR (`CompanyName` = ?)) AND ((? = 1 AND `ContactName` IS NULL) OR (`ContactName` = ?)) AND ((? = 1 AND `ContactTitle` IS NULL) OR (`ContactTitle` = ?)) AND ((? = 1 AND `Address` IS NULL) OR (`Address` = ?)) AND ((? = 1 AND `City` IS NULL) OR (`City` = ?)) AND ((? = 1 AND `Region` IS NULL) OR (`Region` = ?)) AND ((? = 1 AND `PostalCode` IS NULL) OR (`PostalCode` = ?)) AND ((? = 1 AND `Country` IS NULL) OR (`Country` = ?)) AND ((? = 1 AND `Phone` IS NULL) OR (`Phone` = ?)) AND ((? = 1 AND `Fax` IS NULL) OR (`Fax` = ?)))";
this._adapter.DeleteCommand.CommandType = global::System.Data.CommandType.Text;
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_SupplierID", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "SupplierID", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_CompanyName", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "CompanyName", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_CompanyName", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "CompanyName", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_ContactName", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ContactName", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_ContactName", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ContactName", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_ContactTitle", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ContactTitle", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_ContactTitle", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ContactTitle", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_Address", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Address", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_Address", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Address", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_City", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "City", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_City", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "City", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_Region", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Region", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_Region", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Region", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_PostalCode", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "PostalCode", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_PostalCode", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "PostalCode", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_Country", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Country", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_Country", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Country", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_Phone", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Phone", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_Phone", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Phone", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_Fax", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Fax", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_Fax", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Fax", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.InsertCommand = new global::System.Data.OleDb.OleDbCommand();
this._adapter.InsertCommand.Connection = this.Connection;
this._adapter.InsertCommand.CommandText = "INSERT INTO `Suppliers` (`CompanyName`, `ContactName`, `ContactTitle`, `Address`," +
" `City`, `Region`, `PostalCode`, `Country`, `Phone`, `Fax`, `HomePage`) VALUES (" +
"?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)";
this._adapter.InsertCommand.CommandType = global::System.Data.CommandType.Text;
this._adapter.InsertCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("CompanyName", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "CompanyName", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.InsertCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("ContactName", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ContactName", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.InsertCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("ContactTitle", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ContactTitle", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.InsertCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Address", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Address", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.InsertCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("City", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "City", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.InsertCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Region", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Region", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.InsertCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("PostalCode", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "PostalCode", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.InsertCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Country", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Country", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.InsertCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Phone", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Phone", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.InsertCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Fax", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Fax", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.InsertCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("HomePage", global::System.Data.OleDb.OleDbType.LongVarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "HomePage", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.UpdateCommand = new global::System.Data.OleDb.OleDbCommand();
this._adapter.UpdateCommand.Connection = this.Connection;
this._adapter.UpdateCommand.CommandText = @"UPDATE `Suppliers` SET `CompanyName` = ?, `ContactName` = ?, `ContactTitle` = ?, `Address` = ?, `City` = ?, `Region` = ?, `PostalCode` = ?, `Country` = ?, `Phone` = ?, `Fax` = ?, `HomePage` = ? WHERE ((`SupplierID` = ?) AND ((? = 1 AND `CompanyName` IS NULL) OR (`CompanyName` = ?)) AND ((? = 1 AND `ContactName` IS NULL) OR (`ContactName` = ?)) AND ((? = 1 AND `ContactTitle` IS NULL) OR (`ContactTitle` = ?)) AND ((? = 1 AND `Address` IS NULL) OR (`Address` = ?)) AND ((? = 1 AND `City` IS NULL) OR (`City` = ?)) AND ((? = 1 AND `Region` IS NULL) OR (`Region` = ?)) AND ((? = 1 AND `PostalCode` IS NULL) OR (`PostalCode` = ?)) AND ((? = 1 AND `Country` IS NULL) OR (`Country` = ?)) AND ((? = 1 AND `Phone` IS NULL) OR (`Phone` = ?)) AND ((? = 1 AND `Fax` IS NULL) OR (`Fax` = ?)))";
this._adapter.UpdateCommand.CommandType = global::System.Data.CommandType.Text;
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("CompanyName", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "CompanyName", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("ContactName", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ContactName", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("ContactTitle", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ContactTitle", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Address", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Address", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("City", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "City", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Region", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Region", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("PostalCode", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "PostalCode", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Country", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Country", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Phone", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Phone", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Fax", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Fax", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("HomePage", global::System.Data.OleDb.OleDbType.LongVarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "HomePage", global::System.Data.DataRowVersion.Current, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_SupplierID", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "SupplierID", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_CompanyName", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "CompanyName", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_CompanyName", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "CompanyName", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_ContactName", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ContactName", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_ContactName", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ContactName", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_ContactTitle", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ContactTitle", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_ContactTitle", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ContactTitle", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_Address", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Address", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_Address", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Address", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_City", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "City", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_City", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "City", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_Region", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Region", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_Region", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Region", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_PostalCode", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "PostalCode", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_PostalCode", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "PostalCode", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_Country", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Country", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_Country", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Country", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_Phone", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Phone", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_Phone", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Phone", global::System.Data.DataRowVersion.Original, false, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_Fax", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Fax", global::System.Data.DataRowVersion.Original, true, null));
this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_Fax", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Fax", global::System.Data.DataRowVersion.Original, false, null));
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
private void InitConnection() {
this._connection = new global::System.Data.OleDb.OleDbConnection();
this._connection.ConnectionString = System.Configuration.ConfigurationManager.ConnectionStrings["NwindConnectionString"].ConnectionString;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
private void InitCommandCollection() {
this._commandCollection = new global::System.Data.OleDb.OleDbCommand[1];
this._commandCollection[0] = new global::System.Data.OleDb.OleDbCommand();
this._commandCollection[0].Connection = this.Connection;
this._commandCollection[0].CommandText = "SELECT SupplierID, CompanyName, ContactName, ContactTitle, Address, City, Region," +
" PostalCode, Country, Phone, Fax, HomePage FROM Suppliers";
this._commandCollection[0].CommandType = global::System.Data.CommandType.Text;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
[global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Fill, true)]
public virtual int Fill(NorthwindDataSet.SuppliersDataTable dataTable) {
this.Adapter.SelectCommand = this.CommandCollection[0];
if ((this.ClearBeforeFill == true)) {
dataTable.Clear();
}
int returnValue = this.Adapter.Fill(dataTable);
return returnValue;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
[global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, true)]
public virtual NorthwindDataSet.SuppliersDataTable GetData() {
this.Adapter.SelectCommand = this.CommandCollection[0];
NorthwindDataSet.SuppliersDataTable dataTable = new NorthwindDataSet.SuppliersDataTable();
this.Adapter.Fill(dataTable);
return dataTable;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
public virtual int Update(NorthwindDataSet.SuppliersDataTable dataTable) {
return this.Adapter.Update(dataTable);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
public virtual int Update(NorthwindDataSet dataSet) {
return this.Adapter.Update(dataSet, "Suppliers");
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
public virtual int Update(global::System.Data.DataRow dataRow) {
return this.Adapter.Update(new global::System.Data.DataRow[] {
dataRow});
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
public virtual int Update(global::System.Data.DataRow[] dataRows) {
return this.Adapter.Update(dataRows);
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
[global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Delete, true)]
public virtual int Delete(int Original_SupplierID, string Original_CompanyName, string Original_ContactName, string Original_ContactTitle, string Original_Address, string Original_City, string Original_Region, string Original_PostalCode, string Original_Country, string Original_Phone, string Original_Fax) {
this.Adapter.DeleteCommand.Parameters[0].Value = ((int)(Original_SupplierID));
if ((Original_CompanyName == null)) {
throw new global::System.ArgumentNullException("Original_CompanyName");
}
else {
this.Adapter.DeleteCommand.Parameters[1].Value = ((object)(0));
this.Adapter.DeleteCommand.Parameters[2].Value = ((string)(Original_CompanyName));
}
if ((Original_ContactName == null)) {
this.Adapter.DeleteCommand.Parameters[3].Value = ((object)(1));
this.Adapter.DeleteCommand.Parameters[4].Value = global::System.DBNull.Value;
}
else {
this.Adapter.DeleteCommand.Parameters[3].Value = ((object)(0));
this.Adapter.DeleteCommand.Parameters[4].Value = ((string)(Original_ContactName));
}
if ((Original_ContactTitle == null)) {
this.Adapter.DeleteCommand.Parameters[5].Value = ((object)(1));
this.Adapter.DeleteCommand.Parameters[6].Value = global::System.DBNull.Value;
}
else {
this.Adapter.DeleteCommand.Parameters[5].Value = ((object)(0));
this.Adapter.DeleteCommand.Parameters[6].Value = ((string)(Original_ContactTitle));
}
if ((Original_Address == null)) {
this.Adapter.DeleteCommand.Parameters[7].Value = ((object)(1));
this.Adapter.DeleteCommand.Parameters[8].Value = global::System.DBNull.Value;
}
else {
this.Adapter.DeleteCommand.Parameters[7].Value = ((object)(0));
this.Adapter.DeleteCommand.Parameters[8].Value = ((string)(Original_Address));
}
if ((Original_City == null)) {
this.Adapter.DeleteCommand.Parameters[9].Value = ((object)(1));
this.Adapter.DeleteCommand.Parameters[10].Value = global::System.DBNull.Value;
}
else {
this.Adapter.DeleteCommand.Parameters[9].Value = ((object)(0));
this.Adapter.DeleteCommand.Parameters[10].Value = ((string)(Original_City));
}
if ((Original_Region == null)) {
this.Adapter.DeleteCommand.Parameters[11].Value = ((object)(1));
this.Adapter.DeleteCommand.Parameters[12].Value = global::System.DBNull.Value;
}
else {
this.Adapter.DeleteCommand.Parameters[11].Value = ((object)(0));
this.Adapter.DeleteCommand.Parameters[12].Value = ((string)(Original_Region));
}
if ((Original_PostalCode == null)) {
this.Adapter.DeleteCommand.Parameters[13].Value = ((object)(1));
this.Adapter.DeleteCommand.Parameters[14].Value = global::System.DBNull.Value;
}
else {
this.Adapter.DeleteCommand.Parameters[13].Value = ((object)(0));
this.Adapter.DeleteCommand.Parameters[14].Value = ((string)(Original_PostalCode));
}
if ((Original_Country == null)) {
this.Adapter.DeleteCommand.Parameters[15].Value = ((object)(1));
this.Adapter.DeleteCommand.Parameters[16].Value = global::System.DBNull.Value;
}
else {
this.Adapter.DeleteCommand.Parameters[15].Value = ((object)(0));
this.Adapter.DeleteCommand.Parameters[16].Value = ((string)(Original_Country));
}
if ((Original_Phone == null)) {
this.Adapter.DeleteCommand.Parameters[17].Value = ((object)(1));
this.Adapter.DeleteCommand.Parameters[18].Value = global::System.DBNull.Value;
}
else {
this.Adapter.DeleteCommand.Parameters[17].Value = ((object)(0));
this.Adapter.DeleteCommand.Parameters[18].Value = ((string)(Original_Phone));
}
if ((Original_Fax == null)) {
this.Adapter.DeleteCommand.Parameters[19].Value = ((object)(1));
this.Adapter.DeleteCommand.Parameters[20].Value = global::System.DBNull.Value;
}
else {
this.Adapter.DeleteCommand.Parameters[19].Value = ((object)(0));
this.Adapter.DeleteCommand.Parameters[20].Value = ((string)(Original_Fax));
}
global::System.Data.ConnectionState previousConnectionState = this.Adapter.DeleteCommand.Connection.State;
if (((this.Adapter.DeleteCommand.Connection.State & global::System.Data.ConnectionState.Open)
!= global::System.Data.ConnectionState.Open)) {
this.Adapter.DeleteCommand.Connection.Open();
}
try {
int returnValue = this.Adapter.DeleteCommand.ExecuteNonQuery();
return returnValue;
}
finally {
if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
this.Adapter.DeleteCommand.Connection.Close();
}
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
[global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Insert, true)]
public virtual int Insert(string CompanyName, string ContactName, string ContactTitle, string Address, string City, string Region, string PostalCode, string Country, string Phone, string Fax, string HomePage) {
if ((CompanyName == null)) {
throw new global::System.ArgumentNullException("CompanyName");
}
else {
this.Adapter.InsertCommand.Parameters[0].Value = ((string)(CompanyName));
}
if ((ContactName == null)) {
this.Adapter.InsertCommand.Parameters[1].Value = global::System.DBNull.Value;
}
else {
this.Adapter.InsertCommand.Parameters[1].Value = ((string)(ContactName));
}
if ((ContactTitle == null)) {
this.Adapter.InsertCommand.Parameters[2].Value = global::System.DBNull.Value;
}
else {
this.Adapter.InsertCommand.Parameters[2].Value = ((string)(ContactTitle));
}
if ((Address == null)) {
this.Adapter.InsertCommand.Parameters[3].Value = global::System.DBNull.Value;
}
else {
this.Adapter.InsertCommand.Parameters[3].Value = ((string)(Address));
}
if ((City == null)) {
this.Adapter.InsertCommand.Parameters[4].Value = global::System.DBNull.Value;
}
else {
this.Adapter.InsertCommand.Parameters[4].Value = ((string)(City));
}
if ((Region == null)) {
this.Adapter.InsertCommand.Parameters[5].Value = global::System.DBNull.Value;
}
else {
this.Adapter.InsertCommand.Parameters[5].Value = ((string)(Region));
}
if ((PostalCode == null)) {
this.Adapter.InsertCommand.Parameters[6].Value = global::System.DBNull.Value;
}
else {
this.Adapter.InsertCommand.Parameters[6].Value = ((string)(PostalCode));
}
if ((Country == null)) {
this.Adapter.InsertCommand.Parameters[7].Value = global::System.DBNull.Value;
}
else {
this.Adapter.InsertCommand.Parameters[7].Value = ((string)(Country));
}
if ((Phone == null)) {
this.Adapter.InsertCommand.Parameters[8].Value = global::System.DBNull.Value;
}
else {
this.Adapter.InsertCommand.Parameters[8].Value = ((string)(Phone));
}
if ((Fax == null)) {
this.Adapter.InsertCommand.Parameters[9].Value = global::System.DBNull.Value;
}
else {
this.Adapter.InsertCommand.Parameters[9].Value = ((string)(Fax));
}
if ((HomePage == null)) {
this.Adapter.InsertCommand.Parameters[10].Value = global::System.DBNull.Value;
}
else {
this.Adapter.InsertCommand.Parameters[10].Value = ((string)(HomePage));
}
global::System.Data.ConnectionState previousConnectionState = this.Adapter.InsertCommand.Connection.State;
if (((this.Adapter.InsertCommand.Connection.State & global::System.Data.ConnectionState.Open)
!= global::System.Data.ConnectionState.Open)) {
this.Adapter.InsertCommand.Connection.Open();
}
try {
int returnValue = this.Adapter.InsertCommand.ExecuteNonQuery();
return returnValue;
}
finally {
if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
this.Adapter.InsertCommand.Connection.Close();
}
}
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
[global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, true)]
public virtual int Update(
string CompanyName,
string ContactName,
string ContactTitle,
string Address,
string City,
string Region,
string PostalCode,
string Country,
string Phone,
string Fax,
string HomePage,
int Original_SupplierID,
string Original_CompanyName,
string Original_ContactName,
string Original_ContactTitle,
string Original_Address,
string Original_City,
string Original_Region,
string Original_PostalCode,
string Original_Country,
string Original_Phone,
string Original_Fax) {
if ((CompanyName == null)) {
throw new global::System.ArgumentNullException("CompanyName");
}
else {
this.Adapter.UpdateCommand.Parameters[0].Value = ((string)(CompanyName));
}
if ((ContactName == null)) {
this.Adapter.UpdateCommand.Parameters[1].Value = global::System.DBNull.Value;
}
else {
this.Adapter.UpdateCommand.Parameters[1].Value = ((string)(ContactName));
}
if ((ContactTitle == null)) {
this.Adapter.UpdateCommand.Parameters[2].Value = global::System.DBNull.Value;
}
else {
this.Adapter.UpdateCommand.Parameters[2].Value = ((string)(ContactTitle));
}
if ((Address == null)) {
this.Adapter.UpdateCommand.Parameters[3].Value = global::System.DBNull.Value;
}
else {
this.Adapter.UpdateCommand.Parameters[3].Value = ((string)(Address));
}
if ((City == null)) {
this.Adapter.UpdateCommand.Parameters[4].Value = global::System.DBNull.Value;
}
else {
this.Adapter.UpdateCommand.Parameters[4].Value = ((string)(City));
}
if ((Region == null)) {
this.Adapter.UpdateCommand.Parameters[5].Value = global::System.DBNull.Value;
}
else {
this.Adapter.UpdateCommand.Parameters[5].Value = ((string)(Region));
}
if ((PostalCode == null)) {
this.Adapter.UpdateCommand.Parameters[6].Value = global::System.DBNull.Value;
}
else {
this.Adapter.UpdateCommand.Parameters[6].Value = ((string)(PostalCode));
}
if ((Country == null)) {
this.Adapter.UpdateCommand.Parameters[7].Value = global::System.DBNull.Value;
}
else {
this.Adapter.UpdateCommand.Parameters[7].Value = ((string)(Country));
}
if ((Phone == null)) {
this.Adapter.UpdateCommand.Parameters[8].Value = global::System.DBNull.Value;
}
else {
this.Adapter.UpdateCommand.Parameters[8].Value = ((string)(Phone));
}
if ((Fax == null)) {
this.Adapter.UpdateCommand.Parameters[9].Value = global::System.DBNull.Value;
}
else {
this.Adapter.UpdateCommand.Parameters[9].Value = ((string)(Fax));
}
if ((HomePage == null)) {
this.Adapter.UpdateCommand.Parameters[10].Value = global::System.DBNull.Value;
}
else {
this.Adapter.UpdateCommand.Parameters[10].Value = ((string)(HomePage));
}
this.Adapter.UpdateCommand.Parameters[11].Value = ((int)(Original_SupplierID));
if ((Original_CompanyName == null)) {
throw new global::System.ArgumentNullException("Original_CompanyName");
}
else {
this.Adapter.UpdateCommand.Parameters[12].Value = ((object)(0));
this.Adapter.UpdateCommand.Parameters[13].Value = ((string)(Original_CompanyName));
}
if ((Original_ContactName == null)) {
this.Adapter.UpdateCommand.Parameters[14].Value = ((object)(1));
this.Adapter.UpdateCommand.Parameters[15].Value = global::System.DBNull.Value;
}
else {
this.Adapter.UpdateCommand.Parameters[14].Value = ((object)(0));
this.Adapter.UpdateCommand.Parameters[15].Value = ((string)(Original_ContactName));
}
if ((Original_ContactTitle == null)) {
this.Adapter.UpdateCommand.Parameters[16].Value = ((object)(1));
this.Adapter.UpdateCommand.Parameters[17].Value = global::System.DBNull.Value;
}
else {
this.Adapter.UpdateCommand.Parameters[16].Value = ((object)(0));
this.Adapter.UpdateCommand.Parameters[17].Value = ((string)(Original_ContactTitle));
}
if ((Original_Address == null)) {
this.Adapter.UpdateCommand.Parameters[18].Value = ((object)(1));
this.Adapter.UpdateCommand.Parameters[19].Value = global::System.DBNull.Value;
}
else {
this.Adapter.UpdateCommand.Parameters[18].Value = ((object)(0));
this.Adapter.UpdateCommand.Parameters[19].Value = ((string)(Original_Address));
}
if ((Original_City == null)) {
this.Adapter.UpdateCommand.Parameters[20].Value = ((object)(1));
this.Adapter.UpdateCommand.Parameters[21].Value = global::System.DBNull.Value;
}
else {
this.Adapter.UpdateCommand.Parameters[20].Value = ((object)(0));
this.Adapter.UpdateCommand.Parameters[21].Value = ((string)(Original_City));
}
if ((Original_Region == null)) {
this.Adapter.UpdateCommand.Parameters[22].Value = ((object)(1));
this.Adapter.UpdateCommand.Parameters[23].Value = global::System.DBNull.Value;
}
else {
this.Adapter.UpdateCommand.Parameters[22].Value = ((object)(0));
this.Adapter.UpdateCommand.Parameters[23].Value = ((string)(Original_Region));
}
if ((Original_PostalCode == null)) {
this.Adapter.UpdateCommand.Parameters[24].Value = ((object)(1));
this.Adapter.UpdateCommand.Parameters[25].Value = global::System.DBNull.Value;
}
else {
this.Adapter.UpdateCommand.Parameters[24].Value = ((object)(0));
this.Adapter.UpdateCommand.Parameters[25].Value = ((string)(Original_PostalCode));
}
if ((Original_Country == null)) {
this.Adapter.UpdateCommand.Parameters[26].Value = ((object)(1));
this.Adapter.UpdateCommand.Parameters[27].Value = global::System.DBNull.Value;
}
else {
this.Adapter.UpdateCommand.Parameters[26].Value = ((object)(0));
this.Adapter.UpdateCommand.Parameters[27].Value = ((string)(Original_Country));
}
if ((Original_Phone == null)) {
this.Adapter.UpdateCommand.Parameters[28].Value = ((object)(1));
this.Adapter.UpdateCommand.Parameters[29].Value = global::System.DBNull.Value;
}
else {
this.Adapter.UpdateCommand.Parameters[28].Value = ((object)(0));
this.Adapter.UpdateCommand.Parameters[29].Value = ((string)(Original_Phone));
}
if ((Original_Fax == null)) {
this.Adapter.UpdateCommand.Parameters[30].Value = ((object)(1));
this.Adapter.UpdateCommand.Parameters[31].Value = global::System.DBNull.Value;
}
else {
this.Adapter.UpdateCommand.Parameters[30].Value = ((object)(0));
this.Adapter.UpdateCommand.Parameters[31].Value = ((string)(Original_Fax));
}
global::System.Data.ConnectionState previousConnectionState = this.Adapter.UpdateCommand.Connection.State;
if (((this.Adapter.UpdateCommand.Connection.State & global::System.Data.ConnectionState.Open)
!= global::System.Data.ConnectionState.Open)) {
this.Adapter.UpdateCommand.Connection.Open();
}
try {
int returnValue = this.Adapter.UpdateCommand.ExecuteNonQuery();
return returnValue;
}
finally {
if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
this.Adapter.UpdateCommand.Connection.Close();
}
}
}
}
}
#pragma warning restore 1591