org.objectweb.david.libs.binding.orbs.iiop
Class IIOPORB

java.lang.Object
  |
  +--org.omg.CORBA.ORB
        |
        +--org.objectweb.david.libs.binding.orbs.ORBSingletonClass
              |
              +--org.objectweb.david.libs.binding.orbs.ORBClass
                    |
                    +--org.objectweb.david.libs.binding.orbs.iiop.IIOPORB
All Implemented Interfaces:
Constants, DavidMarshallerFactory, JAVA_SERIAL_SERVICE, NamingContext

public class IIOPORB
extends ORBClass
implements NamingContext, JAVA_SERIAL_SERVICE

Encapsulates a IIOPBinder instance under a CORBA compliant interface, by extending ORBClass.


Field Summary
static Properties properties
           
 
Fields inherited from class org.objectweb.david.libs.binding.orbs.ORBClass
domain, marshaller_factory, orb_context, orb_context_name, stub_factory
 
Fields inherited from interface org.objectweb.david.apis.services.java_serial.JAVA_SERIAL_SERVICE
TAG_JAVA_SERIAL
 
Fields inherited from interface org.objectweb.david.libs.binding.orbs.Constants
corba_object_id, corba_prefix, TC_any, TC_boolean, TC_char, TC_double, TC_float, TC_long, TC_longdouble, TC_longlong, TC_null, TC_Object, TC_octet, TC_Principal, TC_short, TC_string, tc_table, TC_TypeCode, TC_ulong, TC_ulonglong, TC_ushort, TC_void, TC_wchar, TC_wstring
 
Constructor Summary
IIOPORB()
          Constructs a new instance of IIOPORB.
 
Method Summary
 Identifier decode(byte[] data, int offset, int length)
          Decodes an identifier from a buffer portion.
 Identifier decode(UnMarshaller u)
          Calls the decode method on the underlying IIOPBinder instance.
 Identifier export(Object id, Context hints)
          Creates a new identifier for the object interface designated by the id parameter.
protected  void initialize()
          Initializes the target IIOPORB instance.
 
Methods inherited from class org.objectweb.david.libs.binding.orbs.ORBClass
connect, create_any, create_output_stream, disconnect, get_next_response, initialize, list_initial_services, newMarshaller, newUnMarshaller, object_to_string, perform_work, poll_next_response, resolve_initial_references, run, send_multiple_requests_deferred, send_multiple_requests_oneway, set_parameters, set_parameters, shutdown, string_to_object, work_pending
 
Methods inherited from class org.objectweb.david.libs.binding.orbs.ORBSingletonClass
create_alias_tc, create_array_tc, create_context_list, create_enum_tc, create_environment, create_exception_list, create_exception_tc, create_interface_tc, create_list, create_named_value, create_operation_list, create_recursive_sequence_tc, create_recursive_tc, create_sequence_tc, create_string_tc, create_struct_tc, create_union_tc, create_value_box_tc, create_value_tc, create_wstring_tc, get_default_context, get_primitive_tc
 
Methods inherited from class org.omg.CORBA.ORB
create_abstract_interface_tc, create_fixed_tc, create_native_tc, create_operation_list, create_policy, get_current, get_service_information, init, init, init
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

properties

public static final Properties properties
Constructor Detail

IIOPORB

public IIOPORB()
Constructs a new instance of IIOPORB.

This method should not be called directly by an application: It is here only to let IIOPORB be instanciated when one of the org.omg.CORBA.ORB.init(...) methods is called.

Method Detail

initialize

protected void initialize()
                   throws JonathanException
Initializes the target IIOPORB instance.

This method is called by set_parameters and set_parameters. It instantiates an IIOPBinder instance, to which all naming and binding-related calls will be forwarded.

Overrides:
initialize in class ORBClass
Parameters:
kernel - a kernel instance
Throws:
JonathanException - if something goes wrong.

export

public Identifier export(Object id,
                         Context hints)
                  throws JonathanException
Creates a new identifier for the object interface designated by the id parameter. id must be of type Identifier.

Calls the export method on the underlying IIOPBinder instance.

Specified by:
export in interface NamingContext
Parameters:
id - an identifier managed by another naming context (probably an adapter);
hints - additional information;
Returns:
an identifier managed by IIOPORB.
Throws:
JonathanException - if something else goes wrong.

decode

public Identifier decode(byte[] data,
                         int offset,
                         int length)
                  throws JonathanException
Decodes an identifier from a buffer portion.

Calls the decode method on the underlying IIOPBinder instance.

Specified by:
decode in interface NamingContext
Parameters:
data - the byte array to read the encoded identifier from;
offset - offset of the first byte of the encoding;
length - length of the encoding;
Returns:
a decoded identifier;
Throws:
JonathanException - if something goes wrong.

decode

public Identifier decode(UnMarshaller u)
                  throws JonathanException
Calls the decode method on the underlying IIOPBinder instance.
Specified by:
decode in interface NamingContext
Parameters:
u - an unmarhaller;
Returns:
an identifier managed by the target naming context;
Throws:
JonathanException - if something goes wrong.