OSB_LIB::TariffClass Class Reference

Inheritance diagram for OSB_LIB::TariffClass:

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

Collaboration graph
[legend]
List of all members.

Detailed Description

A grouping of distance and service dependencies.

A grouping of distance and service dependent charging parameters that together with TariffPeriod determines the tariff to be applied for a given call at any particular point of time.

Remarks:
Copy constructor by compiler.

Definition at line 114 of file tariffclass.h.

Public Types

Public Member Functions

Private Member Functions

Modifying atabase operations:

Private Attributes

Friends


Member Typedef Documentation

typedef Id<TariffClass> OSB_LIB::TariffClass::Oid

Type-safe, unique id of tariff class.

Definition at line 123 of file tariffclass.h.


Constructor & Destructor Documentation

OSB_LIB::TariffClass::TariffClass ( const Oid oid = Oid()  )  [explicit]

Default constructor with optional object id.


Member Function Documentation

bool OSB_LIB::TariffClass::insert ( const OSB_DB::Session session  )  [private]

Insert a tariff class into database.

A new object is inserted. All attributes of the object has been set except object id. The object id will only be set by the function if the insertion is successful.

Parameters:
session Database session.
Returns:
true if success else false.
Exceptions:
OsbException for the following errors:
  • Duplicate name.

const Oid& OSB_LIB::TariffClass::oid (  )  const

Get unique id of tariff class.

bool OSB_LIB::TariffClass::read ( const OSB_DB::Session session  ) 

Read a tariff class from database.

The object id is used to gather other info from database and then populate all the object's data members.

Parameters:
session Database session.
Returns:
true if success else false.

bool OSB_LIB::TariffClass::remove ( const OSB_DB::Session session  )  [private]

Remove a tariff class from database.

After the function call, oid of this object will be unset to indicate that there is no such entry anymore in the database.

Parameters:
session Database session.
Returns:
true if success else false.
Exceptions:
OsbException for the following errors:
  • Object not found.
  • Object has been modified.
  • Version object exists.

bool OSB_LIB::TariffClass::update ( const OSB_DB::Session session  )  [private]

Update a tariff class in the database.

Old entry in the database indentify by the object id will be replaced with the new data from the passed in, upated object.

Parameters:
session Database session used.
Returns:
true if success else false.
Exceptions:
OsbException for the following erros:
  • Name too long.
  • Object not found.
  • Object has been modified.


Friends And Related Function Documentation

friend class OSB_DB::TariffClassGw [friend]

Gateway need to populate private data members.

Definition at line 120 of file tariffclass.h.

friend class TariffCatalogue [friend]

Allow tariff catalogue to invoke the private functions.

Definition at line 118 of file tariffclass.h.


Member Data Documentation

Oid OSB_LIB::TariffClass::oid_ [private]

< Unique id of tariff class.

Definition at line 191 of file tariffclass.h.


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