Chronos Plugins 5.11.0
This documentation covers the plugin interfaces definitions and an example implementation.
Loading...
Searching...
No Matches
MockPlugin.Consumables.CoffeeIngredient Class Reference

Base class for all used mock coffee ingredients. More...

Inheritance diagram for MockPlugin.Consumables.CoffeeIngredient:
Collaboration diagram for MockPlugin.Consumables.CoffeeIngredient:

Public Member Functions

CoffeeIngredient Clone (CoffeeConsumableManager forManager)

Protected Member Functions

 CoffeeIngredient (string ingredientName, MockDevice forDevice, CoffeeConsumableManager parentManager)
virtual void OnPropertyChanged (PropertyChangedEventArgs e)

Protected Attributes

readonly ObservableCollection< IConsumablePuddlemPuddles = new ObservableCollection<IConsumablePuddle>()

Properties

MockDevice ForDevice [get]
IManageConsumables ParentManager [get]
 Reference to the manager that is responsible for this consumable pool.
string ConsumableName [get]
 User readable name of the managed consumable.
ReadOnlyObservableCollection< IConsumablePuddlePuddles [get]
 List of all different "storages" for the consumable. Those have some "location" and can contain a defined amount of the consumable.

Events

PropertyChangedEventHandler PropertyChanged

Private Member Functions

 CoffeeIngredient ()
 CoffeeIngredient (CoffeeIngredient copyFrom, CoffeeConsumableManager forManager)

Detailed Description

Base class for all used mock coffee ingredients.

Definition at line 13 of file CoffeeIngredient.cs.

Constructor & Destructor Documentation

◆ CoffeeIngredient() [1/3]

MockPlugin.Consumables.CoffeeIngredient.CoffeeIngredient ( )
private

Definition at line 15 of file CoffeeIngredient.cs.

16 {
17 Puddles = new ReadOnlyObservableCollection<IConsumablePuddle>(mPuddles);
18 }

References mPuddles, and Puddles.

Referenced by Clone(), and CoffeeIngredient().

◆ CoffeeIngredient() [2/3]

MockPlugin.Consumables.CoffeeIngredient.CoffeeIngredient ( string ingredientName,
MockDevice forDevice,
CoffeeConsumableManager parentManager )
protected

Definition at line 20 of file CoffeeIngredient.cs.

20 : this()
21 {
22 ForDevice = forDevice;
23 ParentManager = parentManager;
24 ConsumableName = ingredientName;
25 }

References ConsumableName, ForDevice, and ParentManager.

◆ CoffeeIngredient() [3/3]

MockPlugin.Consumables.CoffeeIngredient.CoffeeIngredient ( CoffeeIngredient copyFrom,
CoffeeConsumableManager forManager )
private

Definition at line 27 of file CoffeeIngredient.cs.

27 : this()
28 {
29 ForDevice = copyFrom.ForDevice;
30 ParentManager = forManager;
31 ConsumableName = copyFrom.ConsumableName;
32 foreach (var somePuddle in copyFrom.mPuddles.OfType<CoffeeIngredientContainer>().Select(somePuddle => somePuddle.Clone(this)))
33 {
34 mPuddles.Add(somePuddle);
35 }
36 }

References CoffeeIngredient(), ConsumableName, ForDevice, and ParentManager.

Member Function Documentation

◆ Clone()

CoffeeIngredient MockPlugin.Consumables.CoffeeIngredient.Clone ( CoffeeConsumableManager forManager)

Definition at line 47 of file CoffeeIngredient.cs.

48 {
49 return new CoffeeIngredient(this, forManager);
50 }

References CoffeeIngredient().

◆ OnPropertyChanged()

virtual void MockPlugin.Consumables.CoffeeIngredient.OnPropertyChanged ( PropertyChangedEventArgs e)
protectedvirtual

Definition at line 53 of file CoffeeIngredient.cs.

54 {
55 PropertyChanged?.Invoke(this, e);
56 }

References PropertyChanged.

Member Data Documentation

◆ mPuddles

readonly ObservableCollection<IConsumablePuddle> MockPlugin.Consumables.CoffeeIngredient.mPuddles = new ObservableCollection<IConsumablePuddle>()
protected

Definition at line 44 of file CoffeeIngredient.cs.

Referenced by CoffeeIngredient().

Property Documentation

◆ ConsumableName

string MockPlugin.Consumables.CoffeeIngredient.ConsumableName
get

User readable name of the managed consumable.

Implements AxelSemrau.Chronos.Plugin.Consumables.IConsumablePool.

Definition at line 42 of file CoffeeIngredient.cs.

42{ get; }

Referenced by CoffeeIngredient(), and CoffeeIngredient().

◆ ForDevice

MockDevice MockPlugin.Consumables.CoffeeIngredient.ForDevice
get

Definition at line 38 of file CoffeeIngredient.cs.

38{ get; }

Referenced by CoffeeIngredient(), and CoffeeIngredient().

◆ ParentManager

IManageConsumables MockPlugin.Consumables.CoffeeIngredient.ParentManager
get

Reference to the manager that is responsible for this consumable pool.

Implements AxelSemrau.Chronos.Plugin.Consumables.IConsumablePool.

Definition at line 41 of file CoffeeIngredient.cs.

41{ get; }

Referenced by CoffeeIngredient(), and CoffeeIngredient().

◆ Puddles

ReadOnlyObservableCollection<IConsumablePuddle> MockPlugin.Consumables.CoffeeIngredient.Puddles
get

List of all different "storages" for the consumable. Those have some "location" and can contain a defined amount of the consumable.

Implements AxelSemrau.Chronos.Plugin.Consumables.IConsumablePool.

Definition at line 45 of file CoffeeIngredient.cs.

45{ get; }

Referenced by CoffeeIngredient().

Event Documentation

◆ PropertyChanged

PropertyChangedEventHandler MockPlugin.Consumables.CoffeeIngredient.PropertyChanged

Definition at line 40 of file CoffeeIngredient.cs.

Referenced by OnPropertyChanged().


The documentation for this class was generated from the following file: