Skip navigation.

CORBA Programming Reference

  Previous Next vertical dots separating previous/next from contents/index/pdf Contents View as PDF   Get Adobe Reader

 


TP::register_factory()

Synopsis

Locates the BEA Tuxedo FactoryFinder object and registers a BEA Tuxedo factory.

C++ Binding

static void TP::register_factory(
CORBA::Object_ptr factory_or, const char* factory_id);

Arguments

factory_or

Specifies the object reference that was created for an application factory using the TP::create_object_reference() method.

factory_id

Specifies a string identifier that is used to identify the application factory. For some suggestions as to the composition of this string, see Creating CORBA Server Applications.

Exceptions

The following exceptions can be raised by the register_factory() method:

TobjS::CannotProceed

TobjS::InvalidName

Indicates that the id string is empty. It is also raised if the field contains blank spaces or control characters.

TobjS::InvalidObject

Indicates that the factory value is nil.

TobjS::RegistrarNotAvailable

Note: Another possible reason that this exception might occur is that the FactoryFinder cannot participate in a transaction. Therefore, you may need to suspend the current transaction before issuing the TP::register_factory() and TP::unregister_factory() calls. For information on suspending and resuming transactions, see Using CORBA Transactions in the online documentation.

TobjS::OverFlow

Indicates that the id string is longer than 128 bytes (currently the maximum allowable length).

Description

This method locates the BEA Tuxedo FactoryFinder object and registers a BEA Tuxedo factory. Typically, TP::register_factory() is invoked from Server::initialize() when the server creates its factories. The register_factory() method locates the BEA Tuxedo FactoryFinder object and registers the BEA Tuxedo factory.

Caution: Callback objects (that is, those created by a joint client/server directly through the POA) should not be registered with a FactoryFinder.

Return Value

None.

 

Skip navigation bar  Back to Top Previous Next