OSB_LIB::CreditItem Class Reference

Inheritance diagram for OSB_LIB::CreditItem:

Inheritance graph
[legend]
Collaboration diagram for OSB_LIB::CreditItem:

Collaboration graph
[legend]
List of all members.

Detailed Description

Credit as product item.

As a product item a credit is a mere generator of personalized credit.

Remarks:
Copy constructor and assignment by compiler.

Definition at line 286 of file credit.h.

Public Types

Public Member Functions

Static Public Attributes

Private Member Functions

Database operations

Private Attributes

Friends


Member Typedef Documentation

typedef std::auto_ptr<CreditItem> OSB_LIB::CreditItem::AutoPtr

Short-cut for an auto pointer.

For details see quality manual, implementation patterns: Virtual copy construction.

Reimplemented from OSB_LIB::ProductItem.

Definition at line 294 of file credit.h.


Constructor & Destructor Documentation

OSB_LIB::CreditItem::CreditItem ( const ProductItem::Oid oid  ) 

Constructor with object id.

OSB_LIB::CreditItem::CreditItem ( const ProductItem::Oid oid,
const std::string &  name,
const std::string &  des,
const Money money 
)

Constructor with object id, name, des and initial value.


Member Function Documentation

ProductItem::CfgType OSB_LIB::CreditItem::canConfigure (  )  const [inline, virtual]

The configuration type of credit item.

Implements OSB_LIB::ProductItem.

Definition at line 330 of file credit.h.

References OSB_LIB::ProductItem::cfgNone.

ProductItem::DefPersType OSB_LIB::CreditItem::canDefPers (  )  const [inline, virtual]

The default personalization type of credit item.

Implements OSB_LIB::ProductItem.

Definition at line 336 of file credit.h.

References OSB_LIB::ProductItem::defPersMandatory.

virtual CfgPersType OSB_LIB::CreditItem::canPersonalize (  )  const [virtual]

The personalization type of credit item.

Implements OSB_LIB::ProductItem.

AutoPtr OSB_LIB::CreditItem::clone (  )  const

Virtual copy construction.

For details see quality manual, implementation patterns.

Reimplemented from OSB_LIB::ProductItem.

ProductItem* OSB_LIB::CreditItem::clone_ (  )  const [private, virtual]

Virtual copy construction.

For details see quality manual, implementation patterns.

Implements OSB_LIB::ProductItem.

std::auto_ptr<PersProductItem> OSB_LIB::CreditItem::crePersProductItem (  )  const [virtual]

Create a personalized credit.

Id of pers credit will be ID_NOT_SET, initial value will be setted to the credit of pers credit.

Returns:
An auto pointer to pers credit.

Implements OSB_LIB::ProductItem.

const PersProductItem* OSB_LIB::CreditItem::defPersItem (  )  const [virtual]

Pointer to the default personalized product item.

Implements OSB_LIB::ProductItem.

bool OSB_LIB::CreditItem::delSpecific ( const OSB_DB::Session session  )  [private, virtual]

Delete a credit item from the database.

Parameters:
session Database session to use, transactions are not commited.
Returns:
True if the item was found and deleted from the database, else false.

Implements OSB_LIB::ProductItem.

const Money& OSB_LIB::CreditItem::initValue (  )  const

Access initial value of credit item.

bool OSB_LIB::CreditItem::insSpecific ( const OSB_DB::Session session  )  [private, virtual]

Insert a credit item to the database.

Parameters:
session Database session to use, transactions are not commited.
Returns:
True if the item was inserted into the database.

Implements OSB_LIB::ProductItem.

bool OSB_LIB::CreditItem::readSpecific ( const OSB_DB::Session session  )  [private, virtual]

Read a credit item from the database.

Parameters:
session Database session to use, transactions are not commited.
Returns:
True if the item was found and read from the database, else false.

Implements OSB_LIB::ProductItem.

void OSB_LIB::CreditItem::setInitValue ( const Money money  ) 

Modify the initial value of credit item.

Type OSB_LIB::CreditItem::type (  )  const [virtual]

Get the product item type id.

Implements OSB_LIB::ProductItemBase.

bool OSB_LIB::CreditItem::updSpecific ( const OSB_DB::Session session  )  [private, virtual]

Update a credit item in the database.

Parameters:
session Database session to use, transactions are not commited.
Returns:
True if the item was found and updated in the database, else false.

Implements OSB_LIB::ProductItem.


Friends And Related Function Documentation

friend class OSB_DB::CreditItemGw [friend]

Allow the gateway to set data members.

Definition at line 288 of file credit.h.


Member Data Documentation

PersCredit OSB_LIB::CreditItem::defPersCredit_ [private]

Default personalized credit item.

Definition at line 395 of file credit.h.

const Type OSB_LIB::CreditItem::type_ [static]

The type of this product item: PiType::piCredit.

Definition at line 292 of file credit.h.


The documentation for this class was generated from the following file:
Generated on Sat Sep 2 14:11:08 2006 for OSB Library by  doxygen 1.4.7