org.omg.CORBA

Class PolicyHelper

public abstract class PolicyHelper extends Object

The helper operations for the CORBA object {@link Policy}.
Method Summary
static Policyextract(Any any)
Extract the Policy from given Any.
static Stringid()
Get the Policy repository id.
static voidinsert(Any any, Policy that)
Insert the Policy into the given Any.
static Policynarrow(Object obj)
Cast the passed object into the Policy.
static Policyread(InputStream input)
Read the object from the CDR intput stream (IOR profile expected).
static TypeCodetype()
Get the type code of the {@link Policy}.
static voidwrite(OutputStream output, Policy value)
Write the object to the CDR output stream (as IOR profile).

Method Detail

extract

public static Policy extract(Any any)
Extract the Policy from given Any.

Throws: BAD_OPERATION if the passed Any does not contain Policy.

id

public static String id()
Get the Policy repository id.

Returns: "IDL:omg.org/CORBA/Policy:1.0", always.

insert

public static void insert(Any any, Policy that)
Insert the Policy into the given Any.

Parameters: any the Any to insert into. that the Policy to insert.

narrow

public static Policy narrow(Object obj)
Cast the passed object into the Policy. If the object has a different java type, create an instance of the _PolicyStub, using the same delegate, as for the passed parameter. Hence, unlike java type cast, this method may return a different object, than has been passed.

Parameters: obj the object to narrow.

Returns: narrowed instance.

Throws: BAD_PARAM if the passed object is not a Policy.

read

public static Policy read(InputStream input)
Read the object from the CDR intput stream (IOR profile expected).

Parameters: input a org.omg.CORBA.portable stream to read from.

type

public static TypeCode type()
Get the type code of the {@link Policy}.

Returns: interface typecode, named "Policy".

write

public static void write(OutputStream output, Policy value)
Write the object to the CDR output stream (as IOR profile).

Parameters: output a org.omg.CORBA.portable stream stream to write into. value a value to write.