Foodolini.BusinessLogic.BarCode Class Reference

Barcode class contains product name and quantity about a food item, and contains a barcode value and a barcode type to associate with an ingredient. More...

Collaboration diagram for Foodolini.BusinessLogic.BarCode:
Collaboration graph

List of all members.

Public Member Functions

 BarCode (string identifier, string productName, float quantity, Ingredient ingredient, BarCodeType type)
 Creates a new barcode.
 BarCode (string identifier, BarCodeType type)
 Creates a new barcode.
void Save ()
override string ToString ()
 return the Identifer and type of the barcode as a string "Value (type)"

Static Public Member Functions

static BarCode Find (string identifier, BarCodeType barCodeType)
 Searches for a bar code which matches the specified idenifier.

Properties

string Identifier [get, set]
 Gets/sets the Identifier as a System.String.
string ProductName [get, set]
 Gets/sets the ProductName as a System.String.
double Quantity [get, set]
 Gets/sets the Quantity as a System.float.
Ingredient Ingredient [get, set]
 Gets/sets the Ingredient as a Ingredient.
BarCodeType Type [get, set]
 Gets/sets the BarCodeType as a BarCodeType.

Private Member Functions

 BarCode (BarCodeRow row)

Private Attributes

BarCodeRow row
bool modified = true
Ingredient ingredient = null

Detailed Description

Barcode class contains product name and quantity about a food item, and contains a barcode value and a barcode type to associate with an ingredient.

Definition at line 15 of file BarCode.cs.


Constructor & Destructor Documentation

Foodolini.BusinessLogic.BarCode.BarCode ( BarCodeRow  row  )  [private]

Definition at line 20 of file BarCode.cs.

Foodolini.BusinessLogic.BarCode.BarCode ( string  identifier,
string  productName,
float  quantity,
Ingredient  ingredient,
BarCodeType  type 
)

Creates a new barcode.

Parameters:
identifier A System.Int64 representing a identifier.
productName A System.String, representing a product name.
quantity A System.Single, representing the amount of the product.
ingredient A Ingredient, representing the ingredient to wich the barcode is associated with.
type A BarCodeType, representing the type of the barcode.

Definition at line 44 of file BarCode.cs.

Foodolini.BusinessLogic.BarCode.BarCode ( string  identifier,
BarCodeType  type 
)

Creates a new barcode.

Parameters:
identifier A System.Int64 representing a identifier.
type A BarCodeType, representing the type of the barcode.

Definition at line 64 of file BarCode.cs.


Member Function Documentation

static BarCode Foodolini.BusinessLogic.BarCode.Find ( string  identifier,
BarCodeType  barCodeType 
) [static]

Searches for a bar code which matches the specified idenifier.

Parameters:
identifier The bar code to search for
barCodeType The type of bar code
Returns:
A bar code or null if not found

Definition at line 147 of file BarCode.cs.

void Foodolini.BusinessLogic.BarCode.Save (  ) 

Definition at line 157 of file BarCode.cs.

override string Foodolini.BusinessLogic.BarCode.ToString (  ) 

return the Identifer and type of the barcode as a string "Value (type)"

Returns:
A System.String

Definition at line 183 of file BarCode.cs.


Member Data Documentation

Definition at line 111 of file BarCode.cs.

Definition at line 18 of file BarCode.cs.

Definition at line 17 of file BarCode.cs.


Property Documentation

string Foodolini.BusinessLogic.BarCode.Identifier [get, set]

Gets/sets the Identifier as a System.String.

Definition at line 74 of file BarCode.cs.

Ingredient Foodolini.BusinessLogic.BarCode.Ingredient [get, set]

Gets/sets the Ingredient as a Ingredient.

Definition at line 116 of file BarCode.cs.

string Foodolini.BusinessLogic.BarCode.ProductName [get, set]

Gets/sets the ProductName as a System.String.

Definition at line 87 of file BarCode.cs.

double Foodolini.BusinessLogic.BarCode.Quantity [get, set]

Gets/sets the Quantity as a System.float.

Default is 1000 grams

Definition at line 101 of file BarCode.cs.

BarCodeType Foodolini.BusinessLogic.BarCode.Type [get, set]

Gets/sets the BarCodeType as a BarCodeType.

Definition at line 131 of file BarCode.cs.


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

Foodolini 1.0.0 Documentation, generated with DoxyGen.