Java Code Examples for org.omg.CORBA.portable.InputStream.read_any()

The following are Jave code examples for showing how to use read_any() of the org.omg.CORBA.portable.InputStream class. You can vote up the examples you like. Your votes will be used in our system to get more good examples.
Example 1
Project: OpenJSharp   File: Util.java   Source Code and License Vote up 5 votes
/**
 * Reads a java.lang.Object as a CORBA any.
 * @param in the stream from which to read the any.
 * @return the object read from the stream.
 */
public Object readAny(InputStream in)
{
    Any any = in.read_any();
    if ( any.type().kind().value() == TCKind._tk_objref )
        return any.extract_Object ();
    else
        return any.extract_Value();
}
 
Example 2
Project: openjdk-jdk10   File: Util.java   Source Code and License Vote up 5 votes
/**
 * Reads a java.lang.Object as a CORBA any.
 * @param in the stream from which to read the any.
 * @return the object read from the stream.
 */
public Object readAny(InputStream in)
{
    Any any = in.read_any();
    if ( any.type().kind().value() == TCKind._tk_objref )
        return any.extract_Object ();
    else
        return any.extract_Value();
}
 
Example 3
Project: OpenJSharp   File: AnyHolder.java   Source Code and License Vote up 2 votes
/**
 * Reads from <code>input</code> and initalizes the value in the Holder
 * with the unmarshalled data.
 *
 * @param input the InputStream containing CDR formatted data from the wire.
 */
public void _read(InputStream input) {
    value = input.read_any();
}
 
Example 4
Project: openjdk-jdk10   File: AnyHolder.java   Source Code and License Vote up 2 votes
/**
 * Reads from {@code input} and initalizes the value in the Holder
 * with the unmarshalled data.
 *
 * @param input the InputStream containing CDR formatted data from the wire.
 */
public void _read(InputStream input) {
    value = input.read_any();
}