当前位置: 首页>>代码示例>>Java>>正文


Java OutputStream.write_Object方法代码示例

本文整理汇总了Java中org.omg.CORBA.portable.OutputStream.write_Object方法的典型用法代码示例。如果您正苦于以下问题:Java OutputStream.write_Object方法的具体用法?Java OutputStream.write_Object怎么用?Java OutputStream.write_Object使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.omg.CORBA.portable.OutputStream的用法示例。


在下文中一共展示了OutputStream.write_Object方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: StubIORImpl

import org.omg.CORBA.portable.OutputStream; //导入方法依赖的package包/类
public StubIORImpl( org.omg.CORBA.Object obj )
{
    // write the IOR to an OutputStream and get an InputStream
    OutputStream ostr = StubAdapter.getORB( obj ).create_output_stream();
    ostr.write_Object(obj);
    InputStream istr = ostr.create_input_stream();

    // read the IOR components back from the stream
    int typeLength = istr.read_long();
    typeData = new byte[typeLength];
    istr.read_octet_array(typeData, 0, typeLength);
    int numProfiles = istr.read_long();
    profileTags = new int[numProfiles];
    profileData = new byte[numProfiles][];
    for (int i = 0; i < numProfiles; i++) {
        profileTags[i] = istr.read_long();
        profileData[i] = new byte[istr.read_long()];
        istr.read_octet_array(profileData[i], 0, profileData[i].length);
    }
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:21,代码来源:StubIORImpl.java

示例2: writeRemoteObject

import org.omg.CORBA.portable.OutputStream; //导入方法依赖的package包/类
/**
 * Writes a java.lang.Object as a CORBA Object. If <code>obj</code> is
 * an exported RMI-IIOP server object, the tie is found
 * and wired to <code>obj</code>, then written to <code>out.write_Object(org.omg.CORBA.Object)</code>.
 * If <code>obj</code> is a CORBA Object, it is written to
 * <code>out.write_Object(org.omg.CORBA.Object)</code>.
 * @param out the stream in which to write the object.
 * @param obj the object to write.
 */
public void writeRemoteObject(OutputStream out, java.lang.Object obj)
{
    // Make sure we have a connected object, then
    // write it out...

    Object newObj = Utility.autoConnect(obj,out.orb(),false);
    out.write_Object((org.omg.CORBA.Object)newObj);
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:18,代码来源:Util.java

示例3: writeRemoteObject

import org.omg.CORBA.portable.OutputStream; //导入方法依赖的package包/类
/**
 * Writes a java.lang.Object as a CORBA Object. If {@code obj} is
 * an exported RMI-IIOP server object, the tie is found
 * and wired to {@code obj}, then written to {@code out.write_Object(org.omg.CORBA.Object)}.
 * If {@code obj} is a CORBA Object, it is written to
 * {@code out.write_Object(org.omg.CORBA.Object)}.
 * @param out the stream in which to write the object.
 * @param obj the object to write.
 */
public void writeRemoteObject(OutputStream out, java.lang.Object obj)
{
    // Make sure we have a connected object, then
    // write it out...

    Object newObj = Utility.autoConnect(obj,out.orb(),false);
    out.write_Object((org.omg.CORBA.Object)newObj);
}
 
开发者ID:AdoptOpenJDK,项目名称:openjdk-jdk10,代码行数:18,代码来源:Util.java

示例4: _write

import org.omg.CORBA.portable.OutputStream; //导入方法依赖的package包/类
/**
 * Marshals to <code>output</code> the value in
 * this <code>ObjectHolder</code> object.
 *
 * @param output the OutputStream which will contain the CDR formatted data.
 */
public void _write(OutputStream output) {
    output.write_Object(value);
}
 
开发者ID:SunburstApps,项目名称:OpenJSharp,代码行数:10,代码来源:ObjectHolder.java

示例5: _write

import org.omg.CORBA.portable.OutputStream; //导入方法依赖的package包/类
/**
 * Marshals to {@code output} the value in
 * this {@code ObjectHolder} object.
 *
 * @param output the OutputStream which will contain the CDR formatted data.
 */
public void _write(OutputStream output) {
    output.write_Object(value);
}
 
开发者ID:AdoptOpenJDK,项目名称:openjdk-jdk10,代码行数:10,代码来源:ObjectHolder.java


注:本文中的org.omg.CORBA.portable.OutputStream.write_Object方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。