Class ORBSingleton
- All Implemented Interfaces:
TypeCodeFactory
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class com.sun.corba.ee.spi.orb.ORB
ORB.DebugFlagResult, ORB.DummyServant
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static ORB
private static PresentationManager.StubFactoryFactory
Fields inherited from class com.sun.corba.ee.spi.orb.ORB
cdrCacheDebugFlag, cdrDebugFlag, dynamicTypeDebugFlag, folbDebugFlag, giopDebugFlag, giopReadDebugFlag, giopSizeDebugFlag, interceptorDebugFlag, isLocalDebugFlag, mbeanDebugFlag, mbeanFineDebugFlag, mbeanRuntimeDebugFlag, mom, namingDebugFlag, omgWrapper, operationTraceDebugFlag, orbdDebugFlag, orbInitDebug, orbLifecycleDebugFlag, osgiDebugFlag, poaDebugFlag, poaFSMDebugFlag, serviceContextDebugFlag, shutdownDebugFlag, streamFormatVersionDebugFlag, subcontractDebugFlag, transientObjectManagerDebugFlag, transportDebugFlag, valueHandlerDebugFlag, wrapper
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionboolean
void
void
Connects the given servant object (a Java object that is an instance of the server implementation class) to the ORB.create_abstract_interface_tc
(String id, String name) Create aTypeCode
object for an IDL abstract interface.create_alias_tc
(String id, String name, TypeCode original_type) Creates aTypeCode
object representing an IDLalias
(typedef
).Creates an IDLAny
object initialized to contain aTypecode
object whosekind
field is set toTCKind.tc_null
.create_array_tc
(int length, TypeCode element_type) Creates aTypeCode
object representing an IDLarray
.Creates an emptyContextList
object.create_enum_tc
(String id, String name, String[] members) Creates aTypeCode
object representing an IDLenum
.Creates anEnvironment
object.Creates an emptyExceptionList
object.create_exception_tc
(String id, String name, StructMember[] members) Creates aTypeCode
object representing an IDLexception
.create_fixed_tc
(short digits, short scale) Create aTypeCode
object for an IDL fixed type.create_interface_tc
(String id, String name) Creates aTypeCode
object representing an IDLinterface
.create_list
(int count) Allocates anNVList
with (probably) enough space for the specified number ofNamedValue
objects.create_named_value
(String s, Any any, int flags) Creates aNamedValue
object using the given name, value, and argument mode flags.create_native_tc
(String id, String name) Create aTypeCode
object for an IDL native type.create_operation_list
(Object oper) Creates anNVList
initialized with argument descriptions for the operation described in the givenOperationDef
object.Creates a neworg.omg.CORBA.portable.OutputStream
into which IDL method parameters can be marshalled during method invocation.create_policy
(int type, Any val) Can be invoked to create new instances of policy objects of a specific type with specified initial state.create_recursive_sequence_tc
(int bound, int offset) Creates aTypeCode
object representing a a recursive IDLsequence
.Create a recursiveTypeCode
object which serves as a placeholder for a concrete TypeCode during the process of creating TypeCodes which contain recursion.create_sequence_tc
(int bound, TypeCode element_type) Creates aTypeCode
object representing an IDLsequence
.create_string_tc
(int bound) Creates aTypeCode
object representing a bounded IDLstring
.create_struct_tc
(String id, String name, StructMember[] members) Creates aTypeCode
object representing an IDLstruct
.create_union_tc
(String id, String name, TypeCode discriminator_type, UnionMember[] members) Creates aTypeCode
object representing an IDLunion
.create_value_box_tc
(String id, String name, TypeCode boxed_type) Creates aTypeCode
object for an IDL value box.create_value_tc
(String id, String name, short type_modifier, TypeCode concrete_base, ValueMember[] members) Create aTypeCode
object for an IDL value type.create_wstring_tc
(int bound) Creates aTypeCode
object representing a bounded IDLwstring
(wide string).void
void
destroy()
Destroys the ORB so that its resources can be reclaimed.protected void
void
disconnect
(Object obj) Disconnects the given servant object from the ORB.void
Retrieves aCurrent
object.Gets the defaultContext
object.Gets the nextRequest
instance for which a response has been received.get_primitive_tc
(TCKind tckind) Retrieves theTypeCode
object that represents the given primitive IDL type.Returns the ClientDelegateFactory, which is used to create the ClientDelegate that represents an IORgetConnectionCache
(ContactInfo contactInfo) Returns the CorbaContactInfoListFactory, which creates the contact info list that represents possible endpoints in an IOR.private ORB
These are methods from com.sun.corba.ee.impl.se.core.ORBReturns the IOR used for the Full Value Descriptionint
int
int
Obtain the InvocationInterceptor for this ORB instance.Get the LocalResolver used in this ORB.int
int
The ORB configuration dataReturn the bootstrap naming host specified in the ORBInitialHost param.int
Return the bootstrap naming port specified in the ORBInitialPort param.int
Returns the implementation version of the ORBThe RequestDispatcher registry, which contains the request handling codeGet the resolver used in this ORB.getSelector
(int x) Returns the registry for all ServerContext factories of this server.Return the service context cache as nullFactory finders for the various parts of the IOR: tagged components, tagged profiles, and tagged profile templates.Factory finders for the various parts of the IOR: tagged profilesFactory finders for the various parts of the IOR: tagged profile templatesint
Get the transient server IDGet the operation used in string_to_object calls.void
handleBadServerId
(ObjectKey okey) Handle a bad server id for the given object key.void
boolean
boolean
isLocalHost
(String host) boolean
isLocalServerId
(int subcontractId, int serverId) String[]
Returns a list of the initially available CORBA object references, such as "NameService" and "InterfaceRepository".lookup_value_factory
(String repositoryID) void
object_to_string
(Object obj) Converts the given CORBA object reference to a string.void
Performs an implementation-dependent unit of work if called by the main thread.boolean
Finds out if any of the deferred (asynchronous) invocations have a response yet.void
void
register_initial_reference
(String id, Object obj) If this operation is called with an id,"Y"
, and an object,YY
, then a subsequent call toORB.resolve_initial_references( "Y" )
will return objectYY
.register_value_factory
(String repositoryID, ValueFactory factory) Unimplemented methodvoid
registerInitialReference
(String id, org.glassfish.pfl.basic.func.NullaryFunction<Object> closure) void
resolve_initial_references
(String identifier) Resolves a specific object reference from the set of available initial service names.void
run()
This operation blocks the current thread until the ORB has completed the shutdown process, initiated when some thread callsshutdown
.void
Sends multiple dynamic (DII) requests asynchronously.void
Sends multiple dynamic (DII) requests asynchronously without expecting any responses.protected void
set_parameters
(Applet app, Properties props) Allows the ORB implementation to be initialized with the given applet and parameters.protected void
set_parameters
(String[] params, Properties props) Allows the ORB implementation to be initialized with the given parameters and properties.void
set_parameters
(Properties props) void
setBadServerIdHandler
(BadServerIdHandler handler) void
void
void
Set the ServerRequestDispatcher that should be used for handling INS requests.void
setInvocationInterceptor
(InvocationInterceptor interceptor) Set the InvocationInterceptor for this ORB instance.void
setLocalResolver
(LocalResolver resolver) Set the LocalResolver used in this ORB.void
setObjectKeyFactory
(ObjectKeyFactory factory) void
setORBVersion
(ORBVersion verObj) void
setParameters
(String[] params, Properties props) void
setPersistentServerId
(int id) void
setResolver
(Resolver resolver) Set the resolver used in this ORB.void
void
setTypeCodeForClass
(Class c, TypeCodeImpl tcimpl) void
setURLOperation
(Operation stringToObject) Set the operation used in string_to_object calls.void
shutdown
(boolean wait_for_completion) Instructs the ORB to shut down, which causes all object adapters to shut down, in preparation for destruction.
If thewait_for_completion
parameter is true, this operation blocks until all ORB processing (including processing of currently executing requests, object deactivation, and other object adapter operations) has completed.protected void
shutdownServants
(boolean wait_for_completion) void
Converts a string produced by the methodobject_to_string
back to a CORBA object reference.void
unregister_value_factory
(String repositoryID) Unimplemented methodboolean
Returnstrue
if the ORB needs the main thread to perform some work, andfalse
if the ORB does not need the main thread.Methods inherited from class com.sun.corba.ee.spi.orb.ORB
classCodeBaseHandler, classCodeBaseHandler, classNameResolver, classNameResolver, clearDebugFlag, clearDebugFlags, createORBManagedObjectManager, defaultClassNameResolver, extractObjectKeyCacheEntry, get_primitive_tc, getByteBufferPool, getIOR, getIOR, getLogger, getPresentationManager, getStubFactoryFactory, getTypeCode, getUniqueOrbId, getWireObjectKeyTemplate, initializePrimitiveTypeCodeConstants, makeCompositeClassNameResolver, mom, orbIsShutdown, setDebugFlag, setDebugFlags, setRootParentObjectName, setTypeCode
Methods inherited from class org.omg.CORBA_2_3.ORB
get_value_def, set_delegate
Methods inherited from class org.omg.CORBA.ORB
create_basic_dyn_any, create_dyn_any, create_dyn_array, create_dyn_enum, create_dyn_sequence, create_dyn_struct, create_dyn_union, get_service_information, init, init, init
-
Field Details
-
fullORB
-
staticStubFactoryFactory
-
-
Constructor Details
-
ORBSingleton
public ORBSingleton()
-
-
Method Details
-
setParameters
- Specified by:
setParameters
in classORB
-
set_parameters
- Specified by:
set_parameters
in classORB
-
set_parameters
Description copied from class:ORB
Allows the ORB implementation to be initialized with the given applet and parameters. This method, used in applets only, is implemented by subclass ORB implementations and called by the appropriateinit
method to pass in its parameters.- Specified by:
set_parameters
in classORB
- Parameters:
app
- the applet; may benull
props
- applet-specific properties; may benull
-
set_parameters
Description copied from class:ORB
Allows the ORB implementation to be initialized with the given parameters and properties. This method, used in applications only, is implemented by subclass ORB implementations and called by the appropriateinit
method to pass in its parameters.- Specified by:
set_parameters
in classORB
- Parameters:
params
- command-line arguments for the application'smain
method; may benull
props
- application-specific properties; may benull
-
create_output_stream
Description copied from class:ORB
Creates a neworg.omg.CORBA.portable.OutputStream
into which IDL method parameters can be marshalled during method invocation.- Specified by:
create_output_stream
in classORB
- Returns:
- the newly-created
org.omg.CORBA.portable.OutputStream
object
-
create_struct_tc
Description copied from class:ORB
Creates aTypeCode
object representing an IDLstruct
. TheTypeCode
object is initialized with the given id, name, and members.- Specified by:
create_struct_tc
in classORB
- Parameters:
id
- the repository id for thestruct
name
- the name of thestruct
members
- an array describing the members of thestruct
- Returns:
- a newly-created
TypeCode
object describing an IDLstruct
-
create_union_tc
public TypeCode create_union_tc(String id, String name, TypeCode discriminator_type, UnionMember[] members) Description copied from class:ORB
Creates aTypeCode
object representing an IDLunion
. TheTypeCode
object is initialized with the given id, name, discriminator type, and members.- Specified by:
create_union_tc
in classORB
- Parameters:
id
- the repository id of theunion
name
- the name of theunion
discriminator_type
- the type of theunion
discriminatormembers
- an array describing the members of theunion
- Returns:
- a newly-created
TypeCode
object describing an IDLunion
-
create_enum_tc
Description copied from class:ORB
Creates aTypeCode
object representing an IDLenum
. TheTypeCode
object is initialized with the given id, name, and members.- Specified by:
create_enum_tc
in classORB
- Parameters:
id
- the repository id for theenum
name
- the name for theenum
members
- an array describing the members of theenum
- Returns:
- a newly-created
TypeCode
object describing an IDLenum
-
create_alias_tc
Description copied from class:ORB
Creates aTypeCode
object representing an IDLalias
(typedef
). TheTypeCode
object is initialized with the given id, name, and original type.- Specified by:
create_alias_tc
in classORB
- Parameters:
id
- the repository id for the aliasname
- the name for the aliasoriginal_type
- theTypeCode
object describing the original type for which this is an alias- Returns:
- a newly-created
TypeCode
object describing an IDLalias
-
create_exception_tc
Description copied from class:ORB
Creates aTypeCode
object representing an IDLexception
. TheTypeCode
object is initialized with the given id, name, and members.- Specified by:
create_exception_tc
in classORB
- Parameters:
id
- the repository id for theexception
name
- the name for theexception
members
- an array describing the members of theexception
- Returns:
- a newly-created
TypeCode
object describing an IDLexception
-
create_interface_tc
Description copied from class:ORB
Creates aTypeCode
object representing an IDLinterface
. TheTypeCode
object is initialized with the given id and name.- Specified by:
create_interface_tc
in classORB
- Parameters:
id
- the repository id for the interfacename
- the name for the interface- Returns:
- a newly-created
TypeCode
object describing an IDLinterface
-
create_string_tc
Description copied from class:ORB
Creates aTypeCode
object representing a bounded IDLstring
. TheTypeCode
object is initialized with the given bound, which represents the maximum length of the string. Zero indicates that the string described by this type code is unbounded.- Specified by:
create_string_tc
in classORB
- Parameters:
bound
- the bound for thestring
; cannot be negative- Returns:
- a newly-created
TypeCode
object describing a bounded IDLstring
-
create_wstring_tc
Description copied from class:ORB
Creates aTypeCode
object representing a bounded IDLwstring
(wide string). TheTypeCode
object is initialized with the given bound, which represents the maximum length of the wide string. Zero indicates that the string described by this type code is unbounded.- Specified by:
create_wstring_tc
in classORB
- Parameters:
bound
- the bound for thewstring
; cannot be negative- Returns:
- a newly-created
TypeCode
object describing a bounded IDLwstring
-
create_sequence_tc
Description copied from class:ORB
Creates aTypeCode
object representing an IDLsequence
. TheTypeCode
object is initialized with the given bound and element type.- Specified by:
create_sequence_tc
in classORB
- Parameters:
bound
- the bound for thesequence
, 0 if unboundedelement_type
- theTypeCode
object describing the elements contained in thesequence
- Returns:
- a newly-created
TypeCode
object describing an IDLsequence
-
create_recursive_sequence_tc
Description copied from class:ORB
Creates aTypeCode
object representing a a recursive IDLsequence
.For the IDL
struct
Node in following code fragment, the offset parameter for creating its sequence would be 1:Struct Node { long value; Sequence <Node> subnodes; };
- Specified by:
create_recursive_sequence_tc
in classORB
- Parameters:
bound
- the bound for the sequence, 0 if unboundedoffset
- the index to the enclosingTypeCode
object that describes the elements of this sequence- Returns:
- a newly-created
TypeCode
object describing a recursive sequence - See Also:
-
create_array_tc
Description copied from class:ORB
Creates aTypeCode
object representing an IDLarray
. TheTypeCode
object is initialized with the given length and element type.- Specified by:
create_array_tc
in classORB
- Parameters:
length
- the length of thearray
element_type
- aTypeCode
object describing the type of element contained in thearray
- Returns:
- a newly-created
TypeCode
object describing an IDLarray
-
create_native_tc
Description copied from class:ORB
Create aTypeCode
object for an IDL native type.- Overrides:
create_native_tc
in classORB
- Parameters:
id
- the logical id for the native type.name
- the name of the native type.- Returns:
- the requested TypeCode.
-
create_abstract_interface_tc
Description copied from class:ORB
Create aTypeCode
object for an IDL abstract interface.- Overrides:
create_abstract_interface_tc
in classORB
- Parameters:
id
- the logical id for the abstract interface type.name
- the name of the abstract interface type.- Returns:
- the requested TypeCode.
-
create_fixed_tc
Description copied from class:ORB
Create aTypeCode
object for an IDL fixed type.- Overrides:
create_fixed_tc
in classORB
- Parameters:
digits
- specifies the total number of decimal digits in the number and must be from 1 to 31 inclusive.scale
- specifies the position of the decimal point.- Returns:
- the requested TypeCode.
-
create_value_tc
public TypeCode create_value_tc(String id, String name, short type_modifier, TypeCode concrete_base, ValueMember[] members) Description copied from class:ORB
Create aTypeCode
object for an IDL value type. The concrete_base parameter is the TypeCode for the immediate concrete valuetype base of the valuetype for which the TypeCode is being created. It may be null if the valuetype does not have a concrete base.- Overrides:
create_value_tc
in classORB
- Parameters:
id
- the logical id for the value type.name
- the name of the value type.type_modifier
- one of the value type modifier constants: VM_NONE, VM_CUSTOM, VM_ABSTRACT or VM_TRUNCATABLEconcrete_base
- aTypeCode
object describing the concrete valuetype basemembers
- an array containing the members of the value type- Returns:
- the requested TypeCode
-
create_recursive_tc
Description copied from class:ORB
Create a recursiveTypeCode
object which serves as a placeholder for a concrete TypeCode during the process of creating TypeCodes which contain recursion. The id parameter specifies the repository id of the type for which the recursive TypeCode is serving as a placeholder. Once the recursive TypeCode has been properly embedded in the enclosing TypeCode which corresponds to the specified repository id, it will function as a normal TypeCode. Invoking operations on the recursive TypeCode before it has been embedded in the enclosing TypeCode will result in aBAD_TYPECODE
exception.For example, the following IDL type declaration contains recursion:
Struct Node { Sequence<Node> subnodes; };
To create a TypeCode for struct Node, you would invoke the TypeCode creation operations as shown below:
String nodeID = "IDL:Node:1.0"; TypeCode recursiveSeqTC = orb.create_sequence_tc(0, orb.create_recursive_tc(nodeID)); StructMember[] members = { new StructMember("subnodes", recursiveSeqTC, null) }; TypeCode structNodeTC = orb.create_struct_tc(nodeID, "Node", members);
Also note that the following is an illegal IDL type declaration:
Struct Node { Node next; };
Recursive types can only appear within sequences which can be empty. That way marshaling problems, when transmitting the struct in an Any, are avoided.
- Overrides:
create_recursive_tc
in classORB
- Parameters:
id
- the logical id of the referenced type- Returns:
- the requested TypeCode
-
create_value_box_tc
Description copied from class:ORB
Creates aTypeCode
object for an IDL value box.- Overrides:
create_value_box_tc
in classORB
- Parameters:
id
- the logical id for the value typename
- the name of the value typeboxed_type
- the TypeCode for the type- Returns:
- the requested TypeCode
-
get_primitive_tc
Description copied from class:ORB
Retrieves theTypeCode
object that represents the given primitive IDL type.- Specified by:
get_primitive_tc
in classORB
- Parameters:
tckind
- theTCKind
instance corresponding to the desired primitive type- Returns:
- the requested
TypeCode
object
-
create_any
Description copied from class:ORB
Creates an IDLAny
object initialized to contain aTypecode
object whosekind
field is set toTCKind.tc_null
.- Specified by:
create_any
in classORB
- Returns:
- a newly-created
Any
object
-
create_list
Description copied from class:ORB
Allocates anNVList
with (probably) enough space for the specified number ofNamedValue
objects. Note that the specified size is only a hint to help with storage allocation and does not imply the maximum size of the list.- Specified by:
create_list
in classORB
- Parameters:
count
- suggested number ofNamedValue
objects for which to allocate space- Returns:
- the newly-created
NVList
- See Also:
-
create_operation_list
Description copied from class:ORB
Creates anNVList
initialized with argument descriptions for the operation described in the givenOperationDef
object. ThisOperationDef
object is obtained from an Interface Repository. The arguments in the returnedNVList
object are in the same order as in the original IDL operation definition, which makes it possible for the list to be used in dynamic invocation requests.- Overrides:
create_operation_list
in classORB
- Parameters:
oper
- theOperationDef
object to use to create the list- Returns:
- a newly-created
NVList
object containing descriptions of the arguments to the method described in the givenOperationDef
object - See Also:
-
create_named_value
Description copied from class:ORB
Creates aNamedValue
object using the given name, value, and argument mode flags.A
NamedValue
object serves as (1) a parameter or return value or (2) a context property. It may be used by itself or as an element in anNVList
object.- Specified by:
create_named_value
in classORB
- Parameters:
s
- the name of theNamedValue
objectany
- theAny
value to be inserted into theNamedValue
objectflags
- the argument mode flags for theNamedValue
: one ofARG_IN.value
,ARG_OUT.value
, orARG_INOUT.value
.- Returns:
- the newly-created
NamedValue
object - See Also:
-
create_exception_list
Description copied from class:ORB
Creates an emptyExceptionList
object.- Specified by:
create_exception_list
in classORB
- Returns:
- the newly-created
ExceptionList
object
-
create_context_list
Description copied from class:ORB
Creates an emptyContextList
object.- Specified by:
create_context_list
in classORB
- Returns:
- the newly-created
ContextList
object - See Also:
-
get_default_context
Description copied from class:ORB
Gets the defaultContext
object.- Specified by:
get_default_context
in classORB
- Returns:
- the default
Context
object - See Also:
-
create_environment
Description copied from class:ORB
Creates anEnvironment
object.- Specified by:
create_environment
in classORB
- Returns:
- the newly-created
Environment
object - See Also:
-
get_current
Description copied from class:ORB
Retrieves aCurrent
object. TheCurrent
interface is used to manage thread-specific information for use by services such as transactions and security.- Overrides:
get_current
in classORB
- Returns:
- a newly-created
Current
object - See Also:
-
list_initial_services
Description copied from class:ORB
Returns a list of the initially available CORBA object references, such as "NameService" and "InterfaceRepository".- Specified by:
list_initial_services
in classORB
- Returns:
- an array of
String
objects that represent the object references for CORBA services that are initially available with this ORB
-
resolve_initial_references
Description copied from class:ORB
Resolves a specific object reference from the set of available initial service names.- Specified by:
resolve_initial_references
in classORB
- Parameters:
identifier
- the name of the initial service as a string- Returns:
- the object reference associated with the given name
- Throws:
InvalidName
- if the given name is not associated with a known service
-
register_initial_reference
Description copied from class:ORB
If this operation is called with an id,"Y"
, and an object,YY
, then a subsequent call toORB.resolve_initial_references( "Y" )
will return objectYY
.- Overrides:
register_initial_reference
in classORB
- Parameters:
id
- The ID by which the initial reference will be known.obj
- The initial reference itself.- Throws:
InvalidName
- if this operation is called with an empty string id or this operation is called with an id that is already registered, including the default names defined by OMG.
-
send_multiple_requests_oneway
Description copied from class:ORB
Sends multiple dynamic (DII) requests asynchronously without expecting any responses. Note that oneway invocations are not guaranteed to reach the server.- Specified by:
send_multiple_requests_oneway
in classORB
- Parameters:
req
- an array of request objects
-
send_multiple_requests_deferred
Description copied from class:ORB
Sends multiple dynamic (DII) requests asynchronously.- Specified by:
send_multiple_requests_deferred
in classORB
- Parameters:
req
- an array ofRequest
objects
-
poll_next_response
public boolean poll_next_response()Description copied from class:ORB
Finds out if any of the deferred (asynchronous) invocations have a response yet.- Specified by:
poll_next_response
in classORB
- Returns:
true
if there is a response available;false
otherwise
-
get_next_response
Description copied from class:ORB
Gets the nextRequest
instance for which a response has been received.- Specified by:
get_next_response
in classORB
- Returns:
- the next
Request
object ready with a response
-
object_to_string
Description copied from class:ORB
Converts the given CORBA object reference to a string. Note that the format of this string is predefined by IIOP, allowing strings generated by a different ORB to be converted back into an object reference.The resulting
String
object may be stored or communicated in any way that aString
object can be manipulated.- Specified by:
object_to_string
in classORB
- Parameters:
obj
- the object reference to stringify- Returns:
- the string representing the object reference
-
string_to_object
Description copied from class:ORB
Converts a string produced by the methodobject_to_string
back to a CORBA object reference.- Specified by:
string_to_object
in classORB
- Parameters:
s
- the string to be converted back to an object reference. It must be the result of converting an object reference to a string using the methodobject_to_string
.- Returns:
- the object reference
-
string_to_remote
- Throws:
RemoteException
-
connect
Description copied from class:ORB
Connects the given servant object (a Java object that is an instance of the server implementation class) to the ORB. The servant class must extend theImplBase
class corresponding to the interface that is supported by the server. The servant must thus be a CORBA object reference, and inherit fromorg.omg.CORBA.Object
. Servants created by the user can start receiving remote invocations after the methodconnect
has been called. A servant may also be automatically and implicitly connected to the ORB if it is passed as an IDL parameter in an IDL method invocation on a non-local object, that is, if the servant object has to be marshalled and sent outside of the process address space.Calling the method
connect
has no effect when the servant object is already connected to the ORB.Deprecated by the OMG in favor of the Portable Object Adapter APIs.
-
disconnect
Description copied from class:ORB
Disconnects the given servant object from the ORB. After this method returns, the ORB will reject incoming remote requests for the disconnected servant and will send the exceptionorg.omg.CORBA.OBJECT_NOT_EXIST
back to the remote client. Thus the object appears to be destroyed from the point of view of remote clients. Note, however, that local requests issued using the servant directly do not pass through the ORB; hence, they will continue to be processed by the servant.Calling the method
disconnect
has no effect if the servant is not connected to the ORB.Deprecated by the OMG in favor of the Portable Object Adapter APIs.
- Overrides:
disconnect
in classORB
- Parameters:
obj
- The servant object to be disconnected from the ORB
-
run
public void run()Description copied from class:ORB
This operation blocks the current thread until the ORB has completed the shutdown process, initiated when some thread callsshutdown
. It may be used by multiple threads which get all notified when the ORB shuts down. -
shutdown
public void shutdown(boolean wait_for_completion) Description copied from class:ORB
Instructs the ORB to shut down, which causes all object adapters to shut down, in preparation for destruction.
If thewait_for_completion
parameter is true, this operation blocks until all ORB processing (including processing of currently executing requests, object deactivation, and other object adapter operations) has completed. If an application does this in a thread that is currently servicing an invocation, theBAD_INV_ORDER
system exception will be thrown with the OMG minor code 3, since blocking would result in a deadlock.
If thewait_for_completion
parameter isFALSE
, then shutdown may not have completed upon return.While the ORB is in the process of shutting down, the ORB operates as normal, servicing incoming and outgoing requests until all requests have been completed. Once an ORB has shutdown, only object reference management operations may be invoked on the ORB or any object reference obtained from it. An application may also invoke the
destroy
operation on the ORB itself. Invoking any other operation will throw theBAD_INV_ORDER
system exception with the OMG minor code 4.The
ORB.run
method will return aftershutdown
has been called. -
shutdownServants
protected void shutdownServants(boolean wait_for_completion) -
destroyConnections
protected void destroyConnections() -
destroy
public void destroy()Description copied from class:ORB
Destroys the ORB so that its resources can be reclaimed. Any operation invoked on a destroyed ORB reference will throw theOBJECT_NOT_EXIST
exception. Once an ORB has been destroyed, another call toinit
with the same ORBid will return a reference to a newly constructed ORB.If
destroy
is called on an ORB that has not been shut down, it will start the shut down process and block until the ORB has shut down before it destroys the ORB.
If an application callsdestroy
in a thread that is currently servicing an invocation, theBAD_INV_ORDER
system exception will be thrown with the OMG minor code 3, since blocking would result in a deadlock.For maximum portability and to avoid resource leaks, an application should always call
shutdown
anddestroy
on all ORB instances before exiting. -
work_pending
public boolean work_pending()Description copied from class:ORB
Returnstrue
if the ORB needs the main thread to perform some work, andfalse
if the ORB does not need the main thread.- Overrides:
work_pending
in classORB
- Returns:
true
if there is work pending, meaning that the ORB needs the main thread to perform some work;false
if there is no work pending and thus the ORB does not need the main thread
-
perform_work
public void perform_work()Description copied from class:ORB
Performs an implementation-dependent unit of work if called by the main thread. Otherwise it does nothing. The methodswork_pending
andperform_work
can be used in conjunction to implement a simple polling loop that multiplexes the main thread among the ORB and other activities.- Overrides:
perform_work
in classORB
-
register_value_factory
Description copied from class:ORB
Unimplemented method- Overrides:
register_value_factory
in classORB
- Parameters:
repositoryID
- the repository ID.factory
- the factory.- Returns:
- the previously registered factory for the given repository ID, or null if no such factory was previously registered.
- See Also:
-
unregister_value_factory
Description copied from class:ORB
Unimplemented method- Overrides:
unregister_value_factory
in classORB
- Parameters:
repositoryID
- the repository id- See Also:
-
lookup_value_factory
- Overrides:
lookup_value_factory
in classORB
- Parameters:
repositoryID
- the repository id to lookup- Returns:
- the value factory.
- See Also:
-
getTransportManager
- Specified by:
getTransportManager
in classORB
-
getCorbaTransportManager
- Specified by:
getCorbaTransportManager
in classORB
-
getLegacyServerSocketManager
- Specified by:
getLegacyServerSocketManager
in classORB
-
getFullORB
These are methods from com.sun.corba.ee.impl.se.core.ORB -
getInvocationInterceptor
Description copied from class:ORB
Obtain the InvocationInterceptor for this ORB instance. By default this does nothing.- Specified by:
getInvocationInterceptor
in classORB
- Returns:
- The InvocationInterceptor.
-
setInvocationInterceptor
Description copied from class:ORB
Set the InvocationInterceptor for this ORB instance. This will be used around all dynamic RMI-IIOP calls that are mediated by this ORB instance.- Specified by:
setInvocationInterceptor
in classORB
- Parameters:
interceptor
- The InvocationInterceptor to add.
-
getRequestDispatcherRegistry
Description copied from class:ORB
The RequestDispatcher registry, which contains the request handling code- Specified by:
getRequestDispatcherRegistry
in classORB
- Returns:
- The RequestDispatcher registry
-
getServiceContextFactoryRegistry
Description copied from class:ORB
Returns the registry for all ServerContext factories of this server.- Specified by:
getServiceContextFactoryRegistry
in classORB
- Returns:
- the registry.
-
getServiceContextsCache
Return the service context cache as null- Specified by:
getServiceContextsCache
in classORB
- Returns:
null
-
getTransientServerId
public int getTransientServerId()Get the transient server ID- Specified by:
getTransientServerId
in classORB
- Returns:
- throws
SecurityException
-
getORBInitialPort
public int getORBInitialPort()Return the bootstrap naming port specified in the ORBInitialPort param.- Returns:
- throws
SecurityException
-
getORBInitialHost
Return the bootstrap naming host specified in the ORBInitialHost param.- Returns:
- throws
SecurityException
-
getORBServerHost
-
getORBServerPort
public int getORBServerPort() -
getCodeSetComponentInfo
-
isLocalHost
- Specified by:
isLocalHost
in classORB
-
isLocalServerId
public boolean isLocalServerId(int subcontractId, int serverId) - Specified by:
isLocalServerId
in classORB
-
getORBVersion
Description copied from class:ORB
Returns the implementation version of the ORB- Specified by:
getORBVersion
in classORB
- Returns:
- the ORB version.
-
setORBVersion
- Specified by:
setORBVersion
in classORB
-
getAppletHost
-
getAppletCodeBase
-
getHighWaterMark
public int getHighWaterMark() -
getLowWaterMark
public int getLowWaterMark() -
getNumberToReclaim
public int getNumberToReclaim() -
getGIOPFragmentSize
public int getGIOPFragmentSize() -
getGIOPBuffMgrStrategy
-
getFVDCodeBaseIOR
Description copied from class:ORB
Returns the IOR used for the Full Value Description- Specified by:
getFVDCodeBaseIOR
in classORB
- Returns:
- The IOR used for the Full Value Description
-
create_policy
Description copied from class:ORB
Can be invoked to create new instances of policy objects of a specific type with specified initial state. If create_policy fails to instantiate a new Policy object due to its inability to interpret the requested type and content of the policy, it raises the PolicyError exception with the appropriate reason.- Overrides:
create_policy
in classORB
- Parameters:
type
- the PolicyType of the policy object to be createdval
- the value that will be used to set the initial state of the Policy object that is created- Returns:
- Reference to a newly created Policy object of type specified by the type parameter and initialized to a state specified by the val parameter
- Throws:
PolicyError
- when the requested policy is not supported or a requested initial state for the policy is not supported.
-
getServerEndpoint
-
setPersistentServerId
public void setPersistentServerId(int id) -
getTypeCodeForClass
-
setTypeCodeForClass
-
alwaysSendCodeSetServiceContext
public boolean alwaysSendCodeSetServiceContext() -
isDuringDispatch
public boolean isDuringDispatch()- Specified by:
isDuringDispatch
in classORB
-
notifyORB
public void notifyORB() -
getPIHandler
- Specified by:
getPIHandler
in classORB
-
createPIHandler
public void createPIHandler()- Specified by:
createPIHandler
in classORB
-
checkShutdownState
public void checkShutdownState() -
startingDispatch
public void startingDispatch()- Specified by:
startingDispatch
in classORB
-
finishedDispatch
public void finishedDispatch()- Specified by:
finishedDispatch
in classORB
-
registerInitialReference
-
getORBData
Description copied from class:ORB
The ORB configuration data- Specified by:
getORBData
in classORB
- Returns:
- Config data
-
setClientDelegateFactory
- Specified by:
setClientDelegateFactory
in classORB
-
getClientDelegateFactory
Description copied from class:ORB
Returns the ClientDelegateFactory, which is used to create the ClientDelegate that represents an IOR- Specified by:
getClientDelegateFactory
in classORB
- Returns:
- The ClientDelegateFactory
-
setCorbaContactInfoListFactory
- Specified by:
setCorbaContactInfoListFactory
in classORB
-
getCorbaContactInfoListFactory
Description copied from class:ORB
Returns the CorbaContactInfoListFactory, which creates the contact info list that represents possible endpoints in an IOR.- Specified by:
getCorbaContactInfoListFactory
in classORB
- Returns:
- CorbaContactInfoListFactory used
-
getURLOperation
Description copied from class:ORB
Get the operation used in string_to_object calls. The Operation must expect a String and return an org.omg.CORBA.Object.- Specified by:
getURLOperation
in classORB
- Returns:
- operation used
-
setINSDelegate
Description copied from class:ORB
Set the ServerRequestDispatcher that should be used for handling INS requests.- Specified by:
setINSDelegate
in classORB
- Parameters:
sdel
- dispatcher to be used
-
getTaggedComponentFactoryFinder
Description copied from class:ORB
Factory finders for the various parts of the IOR: tagged components, tagged profiles, and tagged profile templates.- Specified by:
getTaggedComponentFactoryFinder
in classORB
- Returns:
- Finder of Factories for TaggedComponents of IORs
-
getTaggedProfileFactoryFinder
Description copied from class:ORB
Factory finders for the various parts of the IOR: tagged profiles- Specified by:
getTaggedProfileFactoryFinder
in classORB
- Returns:
- Finder of Factories for TaggedProfiles of IORs
-
getTaggedProfileTemplateFactoryFinder
Description copied from class:ORB
Factory finders for the various parts of the IOR: tagged profile templates- Specified by:
getTaggedProfileTemplateFactoryFinder
in classORB
- Returns:
- Finder of Factories for TaggedProfileTemplates of IORs
-
getObjectKeyFactory
- Specified by:
getObjectKeyFactory
in classORB
-
setObjectKeyFactory
- Specified by:
setObjectKeyFactory
in classORB
-
handleBadServerId
Description copied from class:ORB
Handle a bad server id for the given object key. This should always through an exception: either a ForwardException to allow another server to handle the request, or else an error indication.- Specified by:
handleBadServerId
in classORB
- Parameters:
okey
- The ObjectKey to check for a valid server id.
-
peekInvocationInfo
- Specified by:
peekInvocationInfo
in classORB
-
pushInvocationInfo
- Specified by:
pushInvocationInfo
in classORB
-
popInvocationInfo
- Specified by:
popInvocationInfo
in classORB
-
createOrIncrementInvocationInfo
- Specified by:
createOrIncrementInvocationInfo
in classORB
-
releaseOrDecrementInvocationInfo
public void releaseOrDecrementInvocationInfo()- Specified by:
releaseOrDecrementInvocationInfo
in classORB
-
getInvocationInfo
- Specified by:
getInvocationInfo
in classORB
-
getConnectionCache
-
setResolver
Description copied from class:ORB
Set the resolver used in this ORB. This resolver will be used for list_initial_services and resolve_initial_references.- Specified by:
setResolver
in classORB
- Parameters:
resolver
- resolver to be used
-
getResolver
Description copied from class:ORB
Get the resolver used in this ORB. This resolver will be used for list_initial_services and resolve_initial_references.- Specified by:
getResolver
in classORB
- Returns:
- ORB Name resolver
-
setLocalResolver
Description copied from class:ORB
Set the LocalResolver used in this ORB. This LocalResolver is used for register_initial_reference only.- Specified by:
setLocalResolver
in classORB
- Parameters:
resolver
- ORB Local Name resolver
-
getLocalResolver
Description copied from class:ORB
Get the LocalResolver used in this ORB. This LocalResolver is used for register_initial_reference only.- Specified by:
getLocalResolver
in classORB
- Returns:
- ORB Local Name resolver
-
setURLOperation
Description copied from class:ORB
Set the operation used in string_to_object calls. The Operation must expect a String and return an org.omg.CORBA.Object.- Specified by:
setURLOperation
in classORB
- Parameters:
stringToObject
- operation to be used
-
setBadServerIdHandler
- Specified by:
setBadServerIdHandler
in classORB
-
initBadServerIdHandler
public void initBadServerIdHandler()- Specified by:
initBadServerIdHandler
in classORB
-
getSelector
-
setThreadPoolManager
- Specified by:
setThreadPoolManager
in classORB
-
getThreadPoolManager
- Specified by:
getThreadPoolManager
in classORB
-
getCopierManager
- Specified by:
getCopierManager
in classORB
-