OSB_CORBA::ProductWriter_i Class Reference

Inheritance diagram for OSB_CORBA::ProductWriter_i:

Inheritance graph
[legend]
Collaboration diagram for OSB_CORBA::ProductWriter_i:

Collaboration graph
[legend]
List of all members.

Detailed Description

Definition of the ProductWriter_i interface.

This interface provides read and write access to the product.

Definition at line 325 of file product_i.h.

Public Member Functions

ProductWriter_i member mutators.
Methods for ProductPart handling.

Static Public Attributes

Private Member Functions

Private Attributes


Constructor & Destructor Documentation

OSB_CORBA::ProductWriter_i::ProductWriter_i ( Product_i prodi,
const OSB_LIB::Product prod,
ProductCatalogue_i pcati,
PortableServer::POA_ptr  ppPoa 
)

Constructor.

virtual OSB_CORBA::ProductWriter_i::~ProductWriter_i (  )  [virtual]

Destructor.

When the destructor is called, the productwriter's servant list is emptied and all the writable part servants are destroyed.


Member Function Documentation

virtual ProductPartWriter_ptr OSB_CORBA::ProductWriter_i::addPart ( const PpTypeId &  pptypeid  )  throw (CORBA::SystemException, OsbCorbaException) [virtual]

Adds a product part to the product.

Parameters:
pptypeid Type of the product part.
Exceptions:
OsbCorbaException 
  • in case the part type is invalid.
  • in case the new part servant cannot be created.

virtual ProductPartWriter_ptr OSB_CORBA::ProductWriter_i::addPart ( const PpTypeId &  pptypeid,
const OSB_LIB::ProductNode::Oid parentId 
) throw (CORBA::SystemException, OsbCorbaException) [virtual]

Adds a product part to a specified parent.

Parameters:
pptypeid Type of the product part.
parentId Id of the parent node.
Exceptions:
OsbCorbaException 
  • in case the part type is invalid.
  • in case the parent cannot be found.
  • in case the new part servant cannot be created.

virtual void OSB_CORBA::ProductWriter_i::checkDowncast ( OSB_LIB::ProductItem item,
const std::string &  module 
) throw (OsbCorbaException) [private, virtual]

Checks that the downcasting of product item is successful.

This method simply checks if the input parameter is null.

Parameters:
item The product item (after downcast).
module The calling module.
Exceptions:
OsbCorbaException 
  • in case the item is 0 (i.e. downcast failed).

virtual void OSB_CORBA::ProductWriter_i::commitChanges (  )  throw (CORBA::SystemException, OsbCorbaException) [virtual]

commit changes made to the productwriter.

Exceptions:
OsbCorbaException 
  • in case any of the changes cannot be made.

ProductPartWriter_ptr OSB_CORBA::ProductWriter_i::createPartWriter ( OSB_LIB::ProductNode node  )  throw (OsbCorbaException) [private]

Creates a ProductPartWriter_i of the correct type.

Parameters:
node The product node.
Exceptions:
OsbCorbaException 
  • in case the part does not exist.
  • in case the servant cannot be created.
Returns:
Reference to a product part writer.

ProductPartWriter_ptr OSB_CORBA::ProductWriter_i::getPartWriter ( const ProductPartId &  id  )  throw (OsbCorbaException) [private]

Get a reference to a product part writer.

Parameters:
id Id of the product part.
Returns:
A product part writer
Exceptions:
OsbCorbaException 
  • in case the part does not exist.
  • in case the servant cannot be created.

virtual ProductPartWriter_ptr OSB_CORBA::ProductWriter_i::getWritablePart ( const ProductPartId &  id  )  throw (CORBA::SystemException, OsbCorbaException) [virtual]

Get a writable product part.

Parameters:
id Id of the product part.
Exceptions:
OsbCorbaException 
  • in case the part does not exist.
  • in case the servant cannot be created.

virtual OSB_LIB::PcatLockMgr::ProductRg OSB_CORBA::ProductWriter_i::lockProduct (  )  throw (OSB_CORBA::OsbCorbaException) [private, virtual]

Overrides the `lockProduct()' method of Product_i.

Returns:
A readguard containing a pointer to the product.
Exceptions:
OsbCorbaException 
  • Never thrown.

Reimplemented from OSB_CORBA::Product_i.

virtual void OSB_CORBA::ProductWriter_i::removePart ( const ProductPartId &  id  )  throw (CORBA::SystemException, OsbCorbaException) [virtual]

Removes a product part.

Parameters:
id Id of the product part.
Exceptions:
OsbCorbaException 
  • in case the part does not exist.
  • in case the part cannot be removed.

virtual void OSB_CORBA::ProductWriter_i::setDesc ( const Utf8String &  desc  )  throw (CORBA::SystemException) [virtual]

Sets the description the productwriter.

Parameters:
desc Description of the productwriter.

virtual void OSB_CORBA::ProductWriter_i::setEndDate ( const Date &  end  )  throw (CORBA::SystemException, OsbCorbaException) [virtual]

Sets the end date of the productwriter.

Parameters:
end End date of the productwriter.

virtual void OSB_CORBA::ProductWriter_i::setName ( const Utf8String &  name  )  throw (CORBA::SystemException) [virtual]

Sets the name of the productwriter.

Parameters:
name Name of the productwriter.

virtual void OSB_CORBA::ProductWriter_i::setStartDate ( const Date &  start  )  throw (CORBA::SystemException, OsbCorbaException) [virtual]

Sets the start date of the productwriter.

Parameters:
start Start date of the productwriter.


Member Data Documentation

const std::string OSB_CORBA::ProductWriter_i::IFC [static]

String representation for ProductWriter_i.

Reimplemented from OSB_CORBA::Product_i.

Definition at line 332 of file product_i.h.

OSB_LIB::Product* OSB_CORBA::ProductWriter_i::prod_ [private]

Own copy of product.

Definition at line 509 of file product_i.h.

Product_i* OSB_CORBA::ProductWriter_i::prodi_ [private]

Pointer to the product servant that issue this writer.

Definition at line 507 of file product_i.h.

PortableServer::POA_ptr OSB_CORBA::ProductWriter_i::writerPoa_ [private]

The writer POA.

Definition at line 511 of file product_i.h.


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