//------------------------------------------------------------------------------
//
// 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.
//
//------------------------------------------------------------------------------
[assembly: global::System.Data.Objects.DataClasses.EdmSchemaAttribute()]
[assembly: global::System.Data.Objects.DataClasses.EdmRelationshipAttribute("PizzaModel", "FK_PizzaOrder_PizzaSize", "PizzaSize", global::System.Data.Metadata.Edm.RelationshipMultiplicity.One, typeof(PizzaModel.PizzaSize), "PizzaOrder", global::System.Data.Metadata.Edm.RelationshipMultiplicity.Many, typeof(PizzaModel.PizzaOrder))]
[assembly: global::System.Data.Objects.DataClasses.EdmRelationshipAttribute("PizzaModel", "OrderTopping", "PizzaOrder", global::System.Data.Metadata.Edm.RelationshipMultiplicity.Many, typeof(PizzaModel.PizzaOrder), "Topping", global::System.Data.Metadata.Edm.RelationshipMultiplicity.Many, typeof(PizzaModel.Topping))]
// Original file name:
// Generation date: 12/15/2007 2:16:34 PM
namespace PizzaModel
{
///
/// There are no comments for PizzaEntities in the schema.
///
public partial class PizzaEntities : global::System.Data.Objects.ObjectContext
{
///
/// Initializes a new PizzaEntities object using the connection string found in the 'PizzaEntities' section of the application configuration file.
///
public PizzaEntities() :
base("name=PizzaEntities", "PizzaEntities")
{
}
///
/// Initialize a new PizzaEntities object.
///
public PizzaEntities(string connectionString) :
base(connectionString, "PizzaEntities")
{
}
///
/// Initialize a new PizzaEntities object.
///
public PizzaEntities(global::System.Data.EntityClient.EntityConnection connection) :
base(connection, "PizzaEntities")
{
}
///
/// There are no comments for PizzaOrder in the schema.
///
[global::System.ComponentModel.BrowsableAttribute(false)]
public global::System.Data.Objects.ObjectQuery PizzaOrder
{
get
{
if ((this._PizzaOrder == null))
{
this._PizzaOrder = base.CreateQuery("[PizzaOrder]");
}
return this._PizzaOrder;
}
}
private global::System.Data.Objects.ObjectQuery _PizzaOrder;
///
/// There are no comments for PizzaSize in the schema.
///
[global::System.ComponentModel.BrowsableAttribute(false)]
public global::System.Data.Objects.ObjectQuery PizzaSize
{
get
{
if ((this._PizzaSize == null))
{
this._PizzaSize = base.CreateQuery("[PizzaSize]");
}
return this._PizzaSize;
}
}
private global::System.Data.Objects.ObjectQuery _PizzaSize;
///
/// There are no comments for SysTime in the schema.
///
[global::System.ComponentModel.BrowsableAttribute(false)]
public global::System.Data.Objects.ObjectQuery SysTime
{
get
{
if ((this._SysTime == null))
{
this._SysTime = base.CreateQuery("[SysTime]");
}
return this._SysTime;
}
}
private global::System.Data.Objects.ObjectQuery _SysTime;
///
/// There are no comments for Topping in the schema.
///
[global::System.ComponentModel.BrowsableAttribute(false)]
public global::System.Data.Objects.ObjectQuery Topping
{
get
{
if ((this._Topping == null))
{
this._Topping = base.CreateQuery("[Topping]");
}
return this._Topping;
}
}
private global::System.Data.Objects.ObjectQuery _Topping;
///
/// There are no comments for PizzaOrder in the schema.
///
public void AddToPizzaOrder(PizzaOrder pizzaOrder)
{
base.AddObject("PizzaOrder", pizzaOrder);
}
///
/// There are no comments for PizzaSize in the schema.
///
public void AddToPizzaSize(PizzaSize pizzaSize)
{
base.AddObject("PizzaSize", pizzaSize);
}
///
/// There are no comments for SysTime in the schema.
///
public void AddToSysTime(SysTime sysTime)
{
base.AddObject("SysTime", sysTime);
}
///
/// There are no comments for Topping in the schema.
///
public void AddToTopping(Topping topping)
{
base.AddObject("Topping", topping);
}
}
///
/// There are no comments for PizzaModel.PizzaOrder in the schema.
///
///
/// ID
///
[global::System.Data.Objects.DataClasses.EdmEntityTypeAttribute(NamespaceName="PizzaModel", Name="PizzaOrder")]
[global::System.Runtime.Serialization.DataContractAttribute()]
[global::System.Serializable()]
public partial class PizzaOrder : global::System.Data.Objects.DataClasses.EntityObject
{
///
/// Create a new PizzaOrder object.
///
/// Initial value of ID.
/// Initial value of RoomNumber.
/// Initial value of Day.
/// Initial value of Status.
public static PizzaOrder CreatePizzaOrder(int ID, int roomNumber, int day, int status)
{
PizzaOrder pizzaOrder = new PizzaOrder();
pizzaOrder.ID = ID;
pizzaOrder.RoomNumber = roomNumber;
pizzaOrder.Day = day;
pizzaOrder.Status = status;
return pizzaOrder;
}
///
/// There are no comments for Property ID in the schema.
///
[global::System.Data.Objects.DataClasses.EdmScalarPropertyAttribute(EntityKeyProperty=true, IsNullable=false)]
[global::System.Runtime.Serialization.DataMemberAttribute()]
public int ID
{
get
{
return this._ID;
}
set
{
this.OnIDChanging(value);
this.ReportPropertyChanging("ID");
this._ID = global::System.Data.Objects.DataClasses.StructuralObject.SetValidValue(value);
this.ReportPropertyChanged("ID");
this.OnIDChanged();
}
}
private int _ID;
partial void OnIDChanging(int value);
partial void OnIDChanged();
///
/// There are no comments for Property RoomNumber in the schema.
///
[global::System.Data.Objects.DataClasses.EdmScalarPropertyAttribute(IsNullable=false)]
[global::System.Runtime.Serialization.DataMemberAttribute()]
public int RoomNumber
{
get
{
return this._RoomNumber;
}
set
{
this.OnRoomNumberChanging(value);
this.ReportPropertyChanging("RoomNumber");
this._RoomNumber = global::System.Data.Objects.DataClasses.StructuralObject.SetValidValue(value);
this.ReportPropertyChanged("RoomNumber");
this.OnRoomNumberChanged();
}
}
private int _RoomNumber;
partial void OnRoomNumberChanging(int value);
partial void OnRoomNumberChanged();
///
/// There are no comments for Property Day in the schema.
///
[global::System.Data.Objects.DataClasses.EdmScalarPropertyAttribute(IsNullable=false)]
[global::System.Runtime.Serialization.DataMemberAttribute()]
public int Day
{
get
{
return this._Day;
}
set
{
this.OnDayChanging(value);
this.ReportPropertyChanging("Day");
this._Day = global::System.Data.Objects.DataClasses.StructuralObject.SetValidValue(value);
this.ReportPropertyChanged("Day");
this.OnDayChanged();
}
}
private int _Day;
partial void OnDayChanging(int value);
partial void OnDayChanged();
///
/// There are no comments for Property Status in the schema.
///
[global::System.Data.Objects.DataClasses.EdmScalarPropertyAttribute(IsNullable=false)]
[global::System.Runtime.Serialization.DataMemberAttribute()]
public int Status
{
get
{
return this._Status;
}
set
{
this.OnStatusChanging(value);
this.ReportPropertyChanging("Status");
this._Status = global::System.Data.Objects.DataClasses.StructuralObject.SetValidValue(value);
this.ReportPropertyChanged("Status");
this.OnStatusChanged();
}
}
private int _Status;
partial void OnStatusChanging(int value);
partial void OnStatusChanged();
///
/// There are no comments for PizzaSize in the schema.
///
[global::System.Data.Objects.DataClasses.EdmRelationshipNavigationPropertyAttribute("PizzaModel", "FK_PizzaOrder_PizzaSize", "PizzaSize")]
[global::System.Xml.Serialization.XmlIgnoreAttribute()]
[global::System.Xml.Serialization.SoapIgnoreAttribute()]
[global::System.ComponentModel.BrowsableAttribute(false)]
public PizzaSize PizzaSize
{
get
{
return ((global::System.Data.Objects.DataClasses.IEntityWithRelationships)(this)).RelationshipManager.GetRelatedReference("PizzaModel.FK_PizzaOrder_PizzaSize", "PizzaSize").Value;
}
set
{
((global::System.Data.Objects.DataClasses.IEntityWithRelationships)(this)).RelationshipManager.GetRelatedReference("PizzaModel.FK_PizzaOrder_PizzaSize", "PizzaSize").Value = value;
}
}
///
/// There are no comments for PizzaSize in the schema.
///
[global::System.Runtime.Serialization.DataMemberAttribute()]
[global::System.ComponentModel.BrowsableAttribute(false)]
public global::System.Data.Objects.DataClasses.EntityReference PizzaSizeReference
{
get
{
return ((global::System.Data.Objects.DataClasses.IEntityWithRelationships)(this)).RelationshipManager.GetRelatedReference("PizzaModel.FK_PizzaOrder_PizzaSize", "PizzaSize");
}
set
{
if ((value != null))
{
((global::System.Data.Objects.DataClasses.IEntityWithRelationships)(this)).RelationshipManager.InitializeRelatedReference("PizzaModel.FK_PizzaOrder_PizzaSize", "PizzaSize", value);
}
}
}
///
/// There are no comments for Topping in the schema.
///
[global::System.Data.Objects.DataClasses.EdmRelationshipNavigationPropertyAttribute("PizzaModel", "OrderTopping", "Topping")]
[global::System.Xml.Serialization.XmlIgnoreAttribute()]
[global::System.Xml.Serialization.SoapIgnoreAttribute()]
[global::System.ComponentModel.BrowsableAttribute(false)]
public global::System.Data.Objects.DataClasses.EntityCollection Topping
{
get
{
return ((global::System.Data.Objects.DataClasses.IEntityWithRelationships)(this)).RelationshipManager.GetRelatedCollection("PizzaModel.OrderTopping", "Topping");
}
}
}
///
/// There are no comments for PizzaModel.PizzaSize in the schema.
///
///
/// ID
///
[global::System.Data.Objects.DataClasses.EdmEntityTypeAttribute(NamespaceName="PizzaModel", Name="PizzaSize")]
[global::System.Runtime.Serialization.DataContractAttribute()]
[global::System.Serializable()]
public partial class PizzaSize : global::System.Data.Objects.DataClasses.EntityObject
{
///
/// Create a new PizzaSize object.
///
/// Initial value of ID.
/// Initial value of SizeName.
public static PizzaSize CreatePizzaSize(int ID, string sizeName)
{
PizzaSize pizzaSize = new PizzaSize();
pizzaSize.ID = ID;
pizzaSize.SizeName = sizeName;
return pizzaSize;
}
///
/// There are no comments for Property ID in the schema.
///
[global::System.Data.Objects.DataClasses.EdmScalarPropertyAttribute(EntityKeyProperty=true, IsNullable=false)]
[global::System.Runtime.Serialization.DataMemberAttribute()]
public int ID
{
get
{
return this._ID;
}
set
{
this.OnIDChanging(value);
this.ReportPropertyChanging("ID");
this._ID = global::System.Data.Objects.DataClasses.StructuralObject.SetValidValue(value);
this.ReportPropertyChanged("ID");
this.OnIDChanged();
}
}
private int _ID;
partial void OnIDChanging(int value);
partial void OnIDChanged();
///
/// There are no comments for Property SizeName in the schema.
///
[global::System.Data.Objects.DataClasses.EdmScalarPropertyAttribute(IsNullable=false)]
[global::System.Runtime.Serialization.DataMemberAttribute()]
public string SizeName
{
get
{
return this._SizeName;
}
set
{
this.OnSizeNameChanging(value);
this.ReportPropertyChanging("SizeName");
this._SizeName = global::System.Data.Objects.DataClasses.StructuralObject.SetValidValue(value, false, 50);
this.ReportPropertyChanged("SizeName");
this.OnSizeNameChanged();
}
}
private string _SizeName;
partial void OnSizeNameChanging(string value);
partial void OnSizeNameChanged();
///
/// There are no comments for PizzaOrder in the schema.
///
[global::System.Data.Objects.DataClasses.EdmRelationshipNavigationPropertyAttribute("PizzaModel", "FK_PizzaOrder_PizzaSize", "PizzaOrder")]
[global::System.Xml.Serialization.XmlIgnoreAttribute()]
[global::System.Xml.Serialization.SoapIgnoreAttribute()]
[global::System.ComponentModel.BrowsableAttribute(false)]
public global::System.Data.Objects.DataClasses.EntityCollection PizzaOrder
{
get
{
return ((global::System.Data.Objects.DataClasses.IEntityWithRelationships)(this)).RelationshipManager.GetRelatedCollection("PizzaModel.FK_PizzaOrder_PizzaSize", "PizzaOrder");
}
}
}
///
/// There are no comments for PizzaModel.SysTime in the schema.
///
///
/// ID
///
[global::System.Data.Objects.DataClasses.EdmEntityTypeAttribute(NamespaceName="PizzaModel", Name="SysTime")]
[global::System.Runtime.Serialization.DataContractAttribute()]
[global::System.Serializable()]
public partial class SysTime : global::System.Data.Objects.DataClasses.EntityObject
{
///
/// Create a new SysTime object.
///
/// Initial value of ID.
/// Initial value of CurrentDay.
/// Initial value of LastReportDay.
public static SysTime CreateSysTime(int ID, int currentDay, int lastReportDay)
{
SysTime sysTime = new SysTime();
sysTime.ID = ID;
sysTime.CurrentDay = currentDay;
sysTime.LastReportDay = lastReportDay;
return sysTime;
}
///
/// There are no comments for Property ID in the schema.
///
[global::System.Data.Objects.DataClasses.EdmScalarPropertyAttribute(EntityKeyProperty=true, IsNullable=false)]
[global::System.Runtime.Serialization.DataMemberAttribute()]
public int ID
{
get
{
return this._ID;
}
set
{
this.OnIDChanging(value);
this.ReportPropertyChanging("ID");
this._ID = global::System.Data.Objects.DataClasses.StructuralObject.SetValidValue(value);
this.ReportPropertyChanged("ID");
this.OnIDChanged();
}
}
private int _ID;
partial void OnIDChanging(int value);
partial void OnIDChanged();
///
/// There are no comments for Property CurrentDay in the schema.
///
[global::System.Data.Objects.DataClasses.EdmScalarPropertyAttribute(IsNullable=false)]
[global::System.Runtime.Serialization.DataMemberAttribute()]
public int CurrentDay
{
get
{
return this._CurrentDay;
}
set
{
this.OnCurrentDayChanging(value);
this.ReportPropertyChanging("CurrentDay");
this._CurrentDay = global::System.Data.Objects.DataClasses.StructuralObject.SetValidValue(value);
this.ReportPropertyChanged("CurrentDay");
this.OnCurrentDayChanged();
}
}
private int _CurrentDay;
partial void OnCurrentDayChanging(int value);
partial void OnCurrentDayChanged();
///
/// There are no comments for Property LastReportDay in the schema.
///
[global::System.Data.Objects.DataClasses.EdmScalarPropertyAttribute(IsNullable=false)]
[global::System.Runtime.Serialization.DataMemberAttribute()]
public int LastReportDay
{
get
{
return this._LastReportDay;
}
set
{
this.OnLastReportDayChanging(value);
this.ReportPropertyChanging("LastReportDay");
this._LastReportDay = global::System.Data.Objects.DataClasses.StructuralObject.SetValidValue(value);
this.ReportPropertyChanged("LastReportDay");
this.OnLastReportDayChanged();
}
}
private int _LastReportDay;
partial void OnLastReportDayChanging(int value);
partial void OnLastReportDayChanged();
}
///
/// There are no comments for PizzaModel.Topping in the schema.
///
///
/// ID
///
[global::System.Data.Objects.DataClasses.EdmEntityTypeAttribute(NamespaceName="PizzaModel", Name="Topping")]
[global::System.Runtime.Serialization.DataContractAttribute()]
[global::System.Serializable()]
public partial class Topping : global::System.Data.Objects.DataClasses.EntityObject
{
///
/// Create a new Topping object.
///
/// Initial value of ID.
/// Initial value of ToppingName.
public static Topping CreateTopping(int ID, string toppingName)
{
Topping topping = new Topping();
topping.ID = ID;
topping.ToppingName = toppingName;
return topping;
}
///
/// There are no comments for Property ID in the schema.
///
[global::System.Data.Objects.DataClasses.EdmScalarPropertyAttribute(EntityKeyProperty=true, IsNullable=false)]
[global::System.Runtime.Serialization.DataMemberAttribute()]
public int ID
{
get
{
return this._ID;
}
set
{
this.OnIDChanging(value);
this.ReportPropertyChanging("ID");
this._ID = global::System.Data.Objects.DataClasses.StructuralObject.SetValidValue(value);
this.ReportPropertyChanged("ID");
this.OnIDChanged();
}
}
private int _ID;
partial void OnIDChanging(int value);
partial void OnIDChanged();
///
/// There are no comments for Property ToppingName in the schema.
///
[global::System.Data.Objects.DataClasses.EdmScalarPropertyAttribute(IsNullable=false)]
[global::System.Runtime.Serialization.DataMemberAttribute()]
public string ToppingName
{
get
{
return this._ToppingName;
}
set
{
this.OnToppingNameChanging(value);
this.ReportPropertyChanging("ToppingName");
this._ToppingName = global::System.Data.Objects.DataClasses.StructuralObject.SetValidValue(value, false, 50);
this.ReportPropertyChanged("ToppingName");
this.OnToppingNameChanged();
}
}
private string _ToppingName;
partial void OnToppingNameChanging(string value);
partial void OnToppingNameChanged();
///
/// There are no comments for PizzaOrder in the schema.
///
[global::System.Data.Objects.DataClasses.EdmRelationshipNavigationPropertyAttribute("PizzaModel", "OrderTopping", "PizzaOrder")]
[global::System.Xml.Serialization.XmlIgnoreAttribute()]
[global::System.Xml.Serialization.SoapIgnoreAttribute()]
[global::System.ComponentModel.BrowsableAttribute(false)]
public global::System.Data.Objects.DataClasses.EntityCollection PizzaOrder
{
get
{
return ((global::System.Data.Objects.DataClasses.IEntityWithRelationships)(this)).RelationshipManager.GetRelatedCollection("PizzaModel.OrderTopping", "PizzaOrder");
}
}
}
}