OSB_LIB::PersE164Item Class Reference

Inheritance diagram for OSB_LIB::PersE164Item:

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

Collaboration graph
[legend]
List of all members.

Detailed Description

E.164 resource as personalized item.

Definition at line 66 of file e164item.h.

Public Types

Public Member Functions

Static Public Attributes

Private Member Functions

Database operations:
For E.164 items, there are no personalization specific data to read:
all functions just wrap to the respective members of PersResource.

Private Attributes


Member Typedef Documentation

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

Short-cut for an auto pointer.

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

Reimplemented from OSB_LIB::PersResource.

Definition at line 72 of file e164item.h.


Constructor & Destructor Documentation

OSB_LIB::PersE164Item::PersE164Item ( const Oid oid = Oid()  ) 

Constructor with optional object id.

OSB_LIB::PersE164Item::PersE164Item ( const PersE164Item rhs  ) 

Copy constructor: copy create the assigned E.164 resources.

OSB_LIB::PersE164Item::~PersE164Item (  ) 

Destructor: delete the assigned E.164 resources.


Member Function Documentation

void OSB_LIB::PersE164Item::assign ( const E164Resource e164  ) 

Assign an E.164 resource.

bool OSB_LIB::PersE164Item::canConfig (  )  const [virtual]

The configuration type of personalized E.164 item.

Returns:
true: Personalized E.164 items allow to assign a E.164 resource.

Implements OSB_LIB::PersProductItem.

AutoPtr OSB_LIB::PersE164Item::clone (  )  const

Virtual copy construction.

For details see quality manual, implementation patterns.

Reimplemented from OSB_LIB::PersResource.

PersProductItem* OSB_LIB::PersE164Item::clone_ (  )  const [private, virtual]

Internal virtual copy constructor.

For details see quality manual, implementation patterns.

Implements OSB_LIB::PersProductItem.

Resource* OSB_LIB::PersE164Item::createResource ( const Resource::Oid resourceId  )  [private]

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

Delete a E.164 item from the database.

Implements OSB_LIB::PersProductItem.

const E164Resource* OSB_LIB::PersE164Item::e164Resource (  )  const

Get assigned E.164 resource.

Returns:
The assigned E.164 resource, it may be 0.

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

Insert a E.164 item from the database.

Implements OSB_LIB::PersProductItem.

Resource* OSB_LIB::PersE164Item::oldResource (  )  [private, virtual]

Non-const access to the previous assigned resource.

Returns:
A pointer to the previous assigned resource. It is 0 if no old resource is assigned.

Implements OSB_LIB::PersResource.

const Resource* OSB_LIB::PersE164Item::oldResource (  )  const [virtual]

Access to the old assigned resource.

Returns:
A pointer to the old assigned resource, it is 0 if no old resource is assigned.

Implements OSB_LIB::PersResource.

PersE164Item& OSB_LIB::PersE164Item::operator= ( const PersE164Item rhs  ) 

Assignment operator: copy create the assigned E.164 resources.

std::string OSB_LIB::PersE164Item::personalization (  )  const [virtual]

Get the personalized resource number.

Returns:
E164Resource::phoneNumber() if a E.164 resource is assigned, else an empty string.

Reimplemented from OSB_LIB::PersResource.

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

Read a E.164 item from the database.

Implements OSB_LIB::PersProductItem.

Resource* OSB_LIB::PersE164Item::resource (  )  [private, virtual]

Non-const access to the assigned resource.

Returns:
A pointer to the assigned resource. It is 0 if no resource is assigned.

Implements OSB_LIB::PersResource.

const Resource* OSB_LIB::PersE164Item::resource (  )  const [virtual]

Access to the assigned resource.

Returns:
A pointer to the assigned resource, it is 0 if no resource is assigned.

Implements OSB_LIB::PersResource.

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

The type of the product item.

The function returns the type of the product item. It is needed for only one reason: Corba clients must provide a configuration window that depends on the actual type.

No appropriate design can be provided: Unless on-line clients use the real product item type through-out the whole live cycle of an object, there must be a way to determine the actual type of a product item. No matter how clever we make our design, for on-line clients there will always be one step where they need to determine a product item's type in a switch-like statement. For this step I personally perfer to work with an enumeration type (and compiler warnings) rather than relying on dynamic casts (where errors can be detected only during run-time).

Remarks:
Derived classes declare the function private.

Implements OSB_LIB::ProductItemBase.

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

Update a E.164 item from the database.

Implements OSB_LIB::PersProductItem.


Member Data Documentation

E164Resource* OSB_LIB::PersE164Item::pE164_ [private]

Pointer to the assigned E.164 resource.

Definition at line 172 of file e164item.h.

E164Resource* OSB_LIB::PersE164Item::pOldE164_ [private]

Pointer to the previously assigned E.164 resource.

Definition at line 174 of file e164item.h.

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

The product item type: PiType::piE164Item.

Definition at line 69 of file e164item.h.


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