OSB_DB::TariffPeriodGw Struct Reference

List of all members.

Detailed Description

Database interface TariffPeriod.

Definition at line 453 of file tariffperiod-gw.h.

Public Member Functions

Private Member Functions

Friends


Member Function Documentation

OSB_LIB::ObjectStatus OSB_DB::TariffPeriodGw::checkObjVs ( const Session session,
const OSB_LIB::TariffPeriod tp 
) [private]

Check the current object version.

Parameters:
session Database session.
tp Object where the object version is to be checked.
Returns:
Result of the object version verification. Possible values are:
  • objUnchanged
  • objModified
  • objDeleted
Exceptions:
OsbException for the following errors:
  • Database error.

bool OSB_DB::TariffPeriodGw::delTariffPeriod ( const Session session,
OSB_LIB::TariffPeriod tp 
) [private]

Delete a tariff period.

Parameters:
session Database session.
tp Tariff period to be deleted.
Returns:
true if successfully deleted else false.
Exceptions:
OsbException for the following errors:
  • Object not found.
  • Object has been modified.
  • Other database errors.

bool OSB_DB::TariffPeriodGw::fetch ( const Session session,
OSB_LIB::TariffPeriod tp 
)

Read a tariff period from database.

This function populates a tariff period based on its oid.

Parameters:
session Database session.
tp Tariff period to be populated.
Returns:
Number of tariff periods retrieved.
Exceptions:
OsbException for any database errors.

long OSB_DB::TariffPeriodGw::fetch ( const Session session,
OSB_LIB::TariffPeriods tps 
)

Retrieve all tariff periods.

This function retrieves all tariff periods from database.

Parameters:
session Database session.
tps A container to store all object retrieved.
Returns:
Number of tariff periods retrieved.
Exceptions:
OsbException for any database errors.

bool OSB_DB::TariffPeriodGw::insTariffPeriod ( const Session session,
OSB_LIB::TariffPeriod tp 
) [private]

Create a new tariff period.

Parameters:
session Database session.
tp New tariff period object.
Returns:
true if success else false.
Exceptions:
OsbException for the following errors:
  • Name too long.
  • Description too long.
  • Duplicate name.
  • Other database errors.

bool OSB_DB::TariffPeriodGw::updTariffPeriod ( const Session session,
OSB_LIB::TariffPeriod tp 
) [private]

Update a tariff period.

This funtion will update the tariff period entry in the database with the one passed in.

Parameters:
session Database session.
tp Updated tariff period object.
Returns:
true is successfully updated else false.
Exceptions:
OsbException for the following errors:
  • Name too long.
  • Descripgion too long.
  • Duplicate name.
  • Object not found.
  • Object has been modified.
  • Other database errors.


Friends And Related Function Documentation

friend class OSB_LIB::TariffPeriod [friend]

Tariff period needs to call the private member functions.

Definition at line 455 of file tariffperiod-gw.h.


The documentation for this struct was generated from the following file:
Generated on Sat Sep 2 14:09:03 2006 for OSB Library by  doxygen 1.4.7