//------------------------------------------------------------------------------
//
// This code was generated by a tool.
// Tango Observables Generator
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated. Do not modify!
//
//------------------------------------------------------------------------------
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using System.Xml.Serialization;
using Newtonsoft.Json;
using System.Linq;
using Tango.DAL.Remote.DB;
using Tango.Core;
using System.ComponentModel;
using Tango.Core.CustomAttributes;
namespace Tango.BL.Entities
{
[Table("IDS_PACKS")]
public abstract class IdsPackBase : ObservableEntity
{
public event EventHandler PackIndexChanged;
public event EventHandler IsEmptyChanged;
public event EventHandler CartridgeTypeChanged;
public event EventHandler ConfigurationChanged;
public event EventHandler DispenserChanged;
public event EventHandler IdsPackFormulaChanged;
public event EventHandler LiquidTypeChanged;
public event EventHandler MidTankTypeChanged;
protected String _configurationguid;
///
/// Gets or sets the idspackbase configuration guid.
///
[Column("CONFIGURATION_GUID")]
[ForeignKey("Configuration")]
public String ConfigurationGuid
{
get
{
return _configurationguid;
}
set
{
if (_configurationguid != value)
{
_configurationguid = value;
}
}
}
protected String _dispenserguid;
///
/// Gets or sets the idspackbase dispenser guid.
///
[Column("DISPENSER_GUID")]
[ForeignKey("Dispenser")]
public String DispenserGuid
{
get
{
return _dispenserguid;
}
set
{
if (_dispenserguid != value)
{
_dispenserguid = value;
}
}
}
protected String _liquidtypeguid;
///
/// Gets or sets the idspackbase liquid type guid.
///
[Column("LIQUID_TYPE_GUID")]
[ForeignKey("LiquidType")]
public String LiquidTypeGuid
{
get
{
return _liquidtypeguid;
}
set
{
if (_liquidtypeguid != value)
{
_liquidtypeguid = value;
}
}
}
protected String _cartridgetypeguid;
///
/// Gets or sets the idspackbase cartridge type guid.
///
[Column("CARTRIDGE_TYPE_GUID")]
[ForeignKey("CartridgeType")]
public String CartridgeTypeGuid
{
get
{
return _cartridgetypeguid;
}
set
{
if (_cartridgetypeguid != value)
{
_cartridgetypeguid = value;
}
}
}
protected String _midtanktypeguid;
///
/// Gets or sets the idspackbase mid tank type guid.
///
[Column("MID_TANK_TYPE_GUID")]
[ForeignKey("MidTankType")]
public String MidTankTypeGuid
{
get
{
return _midtanktypeguid;
}
set
{
if (_midtanktypeguid != value)
{
_midtanktypeguid = value;
}
}
}
protected String _idspackformulaguid;
///
/// Gets or sets the idspackbase ids pack formula guid.
///
[Column("IDS_PACK_FORMULA_GUID")]
[ForeignKey("IdsPackFormula")]
public String IdsPackFormulaGuid
{
get
{
return _idspackformulaguid;
}
set
{
if (_idspackformulaguid != value)
{
_idspackformulaguid = value;
}
}
}
protected Int32 _packindex;
///
/// Gets or sets the idspackbase pack index.
///
[Column("PACK_INDEX")]
public Int32 PackIndex
{
get
{
return _packindex;
}
set
{
if (_packindex != value)
{
_packindex = value;
OnPackIndexChanged(value);
}
}
}
protected Boolean _isempty;
///
/// Gets or sets the idspackbase is empty.
///
[Column("IS_EMPTY")]
public Boolean IsEmpty
{
get
{
return _isempty;
}
set
{
if (_isempty != value)
{
_isempty = value;
OnIsEmptyChanged(value);
}
}
}
protected CartridgeType _cartridgetype;
///
/// Gets or sets the idspackbase cartridge types.
///
[XmlIgnore]
[JsonIgnore]
public virtual CartridgeType CartridgeType
{
get
{
return _cartridgetype;
}
set
{
if (_cartridgetype != value)
{
_cartridgetype = value;
if (CartridgeType != null)
{
CartridgeTypeGuid = CartridgeType.Guid;
}
OnCartridgeTypeChanged(value);
}
}
}
protected Configuration _configuration;
///
/// Gets or sets the idspackbase configuration.
///
[XmlIgnore]
[JsonIgnore]
public virtual Configuration Configuration
{
get
{
return _configuration;
}
set
{
if (_configuration != value)
{
_configuration = value;
if (Configuration != null)
{
ConfigurationGuid = Configuration.Guid;
}
OnConfigurationChanged(value);
}
}
}
protected Dispenser _dispenser;
///
/// Gets or sets the idspackbase dispenser.
///
[XmlIgnore]
[JsonIgnore]
public virtual Dispenser Dispenser
{
get
{
return _dispenser;
}
set
{
if (_dispenser != value)
{
_dispenser = value;
if (Dispenser != null)
{
DispenserGuid = Dispenser.Guid;
}
OnDispenserChanged(value);
}
}
}
protected IdsPackFormula _idspackformula;
///
/// Gets or sets the idspackbase ids pack formulas.
///
[XmlIgnore]
[JsonIgnore]
public virtual IdsPackFormula IdsPackFormula
{
get
{
return _idspackformula;
}
set
{
if (_idspackformula != value)
{
_idspackformula = value;
if (IdsPackFormula != null)
{
IdsPackFormulaGuid = IdsPackFormula.Guid;
}
OnIdsPackFormulaChanged(value);
}
}
}
protected LiquidType _liquidtype;
///
/// Gets or sets the idspackbase liquid types.
///
[XmlIgnore]
[JsonIgnore]
public virtual LiquidType LiquidType
{
get
{
return _liquidtype;
}
set
{
if (_liquidtype != value)
{
_liquidtype = value;
if (LiquidType != null)
{
LiquidTypeGuid = LiquidType.Guid;
}
OnLiquidTypeChanged(value);
}
}
}
protected MidTankType _midtanktype;
///
/// Gets or sets the idspackbase mid tank types.
///
[XmlIgnore]
[JsonIgnore]
public virtual MidTankType MidTankType
{
get
{
return _midtanktype;
}
set
{
if (_midtanktype != value)
{
_midtanktype = value;
if (MidTankType != null)
{
MidTankTypeGuid = MidTankType.Guid;
}
OnMidTankTypeChanged(value);
}
}
}
///
/// Called when the PackIndex has changed.
///
protected virtual void OnPackIndexChanged(Int32 packindex)
{
PackIndexChanged?.Invoke(this, packindex);
RaisePropertyChanged(nameof(PackIndex));
}
///
/// Called when the IsEmpty has changed.
///
protected virtual void OnIsEmptyChanged(Boolean isempty)
{
IsEmptyChanged?.Invoke(this, isempty);
RaisePropertyChanged(nameof(IsEmpty));
}
///
/// Called when the CartridgeType has changed.
///
protected virtual void OnCartridgeTypeChanged(CartridgeType cartridgetype)
{
CartridgeTypeChanged?.Invoke(this, cartridgetype);
RaisePropertyChanged(nameof(CartridgeType));
}
///
/// Called when the Configuration has changed.
///
protected virtual void OnConfigurationChanged(Configuration configuration)
{
ConfigurationChanged?.Invoke(this, configuration);
RaisePropertyChanged(nameof(Configuration));
}
///
/// Called when the Dispenser has changed.
///
protected virtual void OnDispenserChanged(Dispenser dispenser)
{
DispenserChanged?.Invoke(this, dispenser);
RaisePropertyChanged(nameof(Dispenser));
}
///
/// Called when the IdsPackFormula has changed.
///
protected virtual void OnIdsPackFormulaChanged(IdsPackFormula idspackformula)
{
IdsPackFormulaChanged?.Invoke(this, idspackformula);
RaisePropertyChanged(nameof(IdsPackFormula));
}
///
/// Called when the LiquidType has changed.
///
protected virtual void OnLiquidTypeChanged(LiquidType liquidtype)
{
LiquidTypeChanged?.Invoke(this, liquidtype);
RaisePropertyChanged(nameof(LiquidType));
}
///
/// Called when the MidTankType has changed.
///
protected virtual void OnMidTankTypeChanged(MidTankType midtanktype)
{
MidTankTypeChanged?.Invoke(this, midtanktype);
RaisePropertyChanged(nameof(MidTankType));
}
///
/// Initializes a new instance of the class.
///
public IdsPackBase() : base()
{
}
}
}