public final class DynAnyFactoryHolder extends Object implements Streamable
Dynamic interpretation of an any usually involves creating a DynAny object using create_dyn_any() as the first step. Depending on the type of the any, the resulting DynAny object reference can be narrowed to a DynFixed, DynStruct, DynSequence, DynArray, DynUnion, DynEnum, or DynValue object reference.
Dynamic creation of an any involves creating a DynAny object using create_dyn_any_from_type_code(), passing the TypeCode associated with the value to be created. The returned reference is narrowed to one of the complex types, such as DynStruct, if appropriate. Then, the value can be initialized by means of invoking operations on the resulting object. Finally, the to_any operation can be invoked to create an any value from the constructed DynAny.
Modifier and Type | Field and Description |
---|---|
DynAnyFactory |
value |
Constructor and Description |
---|
DynAnyFactoryHolder() |
DynAnyFactoryHolder(DynAnyFactory initialValue) |
Modifier and Type | Method and Description |
---|---|
void |
_read(InputStream i)
Reads data from
istream and initalizes the
value field of the Holder with the unmarshalled data. |
TypeCode |
_type()
Retrieves the
TypeCode object corresponding to the value
in the value field of the Holder. |
void |
_write(OutputStream o)
Marshals to
ostream the value in the
value field of the Holder. |
public DynAnyFactory value
public DynAnyFactoryHolder()
public DynAnyFactoryHolder(DynAnyFactory initialValue)
public void _read(InputStream i)
Streamable
istream
and initalizes the
value
field of the Holder with the unmarshalled data._read
in interface Streamable
i
- the InputStream that represents the CDR data from the wire.public void _write(OutputStream o)
Streamable
ostream
the value in the
value
field of the Holder._write
in interface Streamable
o
- the CDR OutputStreampublic TypeCode _type()
Streamable
TypeCode
object corresponding to the value
in the value
field of the Holder._type
in interface Streamable
TypeCode
object for the value held in the holderCopyright © 2017 JBoss by Red Hat. All rights reserved.