Java Code Examples for org.omg.CORBA.portable.OutputStream#write_char()

The following examples show how to use org.omg.CORBA.portable.OutputStream#write_char() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: CorbaStreamableTest.java    From cxf with Apache License 2.0 6 votes vote down vote up
@Test
public void testReadStreamable() {
    QName objName = new QName("object");
    QName objIdlType = new QName(CorbaConstants.NU_WSDL_CORBA, "char", CorbaConstants.NP_WSDL_CORBA);
    TypeCode objTypeCode = orb.get_primitive_tc(TCKind.tk_char);
    CorbaPrimitiveHandler obj = new CorbaPrimitiveHandler(objName, objIdlType, objTypeCode, null);
    CorbaStreamable streamable = new CorbaStreamableImpl(obj, objName);

    OutputStream oStream = orb.create_output_stream();
    oStream.write_char('c');

    InputStream iStream = oStream.create_input_stream();
    streamable._read(iStream);
    CorbaPrimitiveHandler streamableObj = (CorbaPrimitiveHandler)streamable.getObject();
    Object o = streamableObj.getValue();

    assertTrue(o instanceof Character);
    Character charValue = (Character)o;
    assertTrue(charValue.charValue() == 'c');
}
 
Example 2
Source File: CorbaObjectReaderTest.java    From cxf with Apache License 2.0 5 votes vote down vote up
@Test
public void testReadChar() {
    OutputStream oStream = orb.create_output_stream();
    oStream.write_char('c');

    InputStream iStream = oStream.create_input_stream();
    CorbaObjectReader reader = new CorbaObjectReader(iStream);

    Character charValue = reader.readChar();
    assertTrue(charValue.charValue() == 'c');
}
 
Example 3
Source File: CharHolder.java    From jdk1.8-source-analysis with Apache License 2.0 2 votes vote down vote up
/**
 * Marshals to <code>output</code> the value in
 * this <code>CharHolder</code> object.
 *
 * @param output the OutputStream which will contain the CDR formatted data
 */
public void _write(OutputStream output) {
    output.write_char(value);
}
 
Example 4
Source File: CharHolder.java    From TencentKona-8 with GNU General Public License v2.0 2 votes vote down vote up
/**
 * Marshals to <code>output</code> the value in
 * this <code>CharHolder</code> object.
 *
 * @param output the OutputStream which will contain the CDR formatted data
 */
public void _write(OutputStream output) {
    output.write_char(value);
}
 
Example 5
Source File: CharHolder.java    From jdk8u60 with GNU General Public License v2.0 2 votes vote down vote up
/**
 * Marshals to <code>output</code> the value in
 * this <code>CharHolder</code> object.
 *
 * @param output the OutputStream which will contain the CDR formatted data
 */
public void _write(OutputStream output) {
    output.write_char(value);
}
 
Example 6
Source File: CharHolder.java    From JDKSourceCode1.8 with MIT License 2 votes vote down vote up
/**
 * Marshals to <code>output</code> the value in
 * this <code>CharHolder</code> object.
 *
 * @param output the OutputStream which will contain the CDR formatted data
 */
public void _write(OutputStream output) {
    output.write_char(value);
}
 
Example 7
Source File: CharHolder.java    From openjdk-jdk8u with GNU General Public License v2.0 2 votes vote down vote up
/**
 * Marshals to <code>output</code> the value in
 * this <code>CharHolder</code> object.
 *
 * @param output the OutputStream which will contain the CDR formatted data
 */
public void _write(OutputStream output) {
    output.write_char(value);
}
 
Example 8
Source File: CharHolder.java    From openjdk-jdk8u-backup with GNU General Public License v2.0 2 votes vote down vote up
/**
 * Marshals to <code>output</code> the value in
 * this <code>CharHolder</code> object.
 *
 * @param output the OutputStream which will contain the CDR formatted data
 */
public void _write(OutputStream output) {
    output.write_char(value);
}
 
Example 9
Source File: CharHolder.java    From openjdk-jdk9 with GNU General Public License v2.0 2 votes vote down vote up
/**
 * Marshals to {@code output} the value in
 * this {@code CharHolder} object.
 *
 * @param output the OutputStream which will contain the CDR formatted data
 */
public void _write(OutputStream output) {
    output.write_char(value);
}
 
Example 10
Source File: CharHolder.java    From Java8CN with Apache License 2.0 2 votes vote down vote up
/**
 * Marshals to <code>output</code> the value in
 * this <code>CharHolder</code> object.
 *
 * @param output the OutputStream which will contain the CDR formatted data
 */
public void _write(OutputStream output) {
    output.write_char(value);
}
 
Example 11
Source File: CharHolder.java    From hottub with GNU General Public License v2.0 2 votes vote down vote up
/**
 * Marshals to <code>output</code> the value in
 * this <code>CharHolder</code> object.
 *
 * @param output the OutputStream which will contain the CDR formatted data
 */
public void _write(OutputStream output) {
    output.write_char(value);
}
 
Example 12
Source File: CharHolder.java    From openjdk-8-source with GNU General Public License v2.0 2 votes vote down vote up
/**
 * Marshals to <code>output</code> the value in
 * this <code>CharHolder</code> object.
 *
 * @param output the OutputStream which will contain the CDR formatted data
 */
public void _write(OutputStream output) {
    output.write_char(value);
}
 
Example 13
Source File: CharHolder.java    From openjdk-8 with GNU General Public License v2.0 2 votes vote down vote up
/**
 * Marshals to <code>output</code> the value in
 * this <code>CharHolder</code> object.
 *
 * @param output the OutputStream which will contain the CDR formatted data
 */
public void _write(OutputStream output) {
    output.write_char(value);
}