JavaTM 2 Platform
Standard Ed. 6

org.omg.CORBA.portable
类 OutputStream

java.lang.Object
  继承者 java.io.OutputStream
      继承者 org.omg.CORBA.portable.OutputStream
所有已实现的接口:
Closeable, Flushable
直接已知子类:
OutputStream

public abstract class OutputStream
extends OutputStream

OuputStream 是用来将 IDL 类型写入 CDR 编组流的 Java API。这些方法供 ORB 用来编组 IDL 类型以及将 IDL 插入 Any。这些 _array 形式的方法可以直接用于写入 IDL 类型的序列和数组。

从以下版本开始:
JDK1.2

构造方法摘要
OutputStream()
           
 
方法摘要
abstract  InputStream create_input_stream()
          返回一个具有相同缓冲区的输入流。
 ORB orb()
          返回创建此 OutputStream 的 ORB。
abstract  void write_any(Any value)
          在此输出流上写入一个 Any。
abstract  void write_boolean_array(boolean[] value, int offset, int length)
          在此输出流上写入一个 boolean 数组。
abstract  void write_boolean(boolean value)
          将一个 boolean 值写入此流。
abstract  void write_char_array(char[] value, int offset, int length)
          在此输出流上写入一个 char 数组。
abstract  void write_char(char value)
          将一个 char 值写入此流。
 void write_Context(Context ctx, ContextList contexts)
          在此流上写入一个 CORBA 上下文。
abstract  void write_double_array(double[] value, int offset, int length)
          在此输入流上写入一个 double 数组。
abstract  void write_double(double value)
          将一个 double 值写入此流。
 void write_fixed(BigDecimal value)
          写入一个 BigDecimal 数。
abstract  void write_float_array(float[] value, int offset, int length)
          在此输入流上写入一个 float 数组。
abstract  void write_float(float value)
          将一个 float 值写入此流。
abstract  void write_long_array(int[] value, int offset, int length)
          在此输出流上写入一个 CORBA long(即 Java int)数组。
abstract  void write_long(int value)
          将一个 CORBA long(即 Java int)值写入此流。
abstract  void write_longlong_array(long[] value, int offset, int length)
          在此输出流上写入一个 CORBA longlong(即 Java int)数组。
abstract  void write_longlong(long value)
          将一个 CORBA longlong(即 Java long)值写入此流。
abstract  void write_Object(Object value)
          在此输入流上写入一个 CORBA Object。
abstract  void write_octet_array(byte[] value, int offset, int length)
          在此输出流上写入一个 CORBA 八位组 (byte) 数组。
abstract  void write_octet(byte value)
          将一个 CORBA 八位组(即字节)写入此流。
 void write_Principal(Principal value)
          已过时。 已由 CORBA 2.2 取代。
abstract  void write_short_array(short[] value, int offset, int length)
          在此输出流上写入一个 short 数组。
abstract  void write_short(short value)
          将一个 short 值写入此流。
abstract  void write_string(String value)
          将一个 string 值写入此流。
abstract  void write_TypeCode(TypeCode value)
          在此输出流上写入一个 TypeCode。
abstract  void write_ulong_array(int[] value, int offset, int length)
          在此输出流上写入一个无符号 CORBA long(即 Java int)数组。
abstract  void write_ulong(int value)
          将一个无符号 CORBA long(即 Java int)值写入此流。
abstract  void write_ulonglong_array(long[] value, int offset, int length)
          在此输出流上写入一个无符号 CORBA longlong(即 Java int)数组。
abstract  void write_ulonglong(long value)
          将一个无符号 CORBA longlong(即 Java long)值写入此流。
abstract  void write_ushort_array(short[] value, int offset, int length)
          在此输出流上写入一个无符号 short 数组。
abstract  void write_ushort(short value)
          将一个无符号 short 值写入此流。
abstract  void write_wchar_array(char[] value, int offset, int length)
          在此输出流上写入一个 wide char 数组。
abstract  void write_wchar(char value)
          将一个 wide char 值写入此流。
abstract  void write_wstring(String value)
          将一个 wide string 值写入此流。
 void write(int b)
          将一个 integer(数组长度)写入此流。
 
从类 java.io.OutputStream 继承的方法
close, flush, write, write
 
从类 java.lang.Object 继承的方法
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

构造方法详细信息

OutputStream

public OutputStream()
方法详细信息

create_input_stream

public abstract InputStream create_input_stream()
返回一个具有相同缓冲区的输入流。

返回:
具有相同缓冲区的输入流。

write_boolean

public abstract void write_boolean(boolean value)
将一个 boolean 值写入此流。

参数:
value - 要写入的值。

write_char

public abstract void write_char(char value)
将一个 char 值写入此流。

参数:
value - 要写入的值。

write_wchar

public abstract void write_wchar(char value)
将一个 wide char 值写入此流。

参数:
value - 要写入的值。

write_octet

public abstract void write_octet(byte value)
将一个 CORBA 八位组(即字节)写入此流。

参数:
value - 要写入的值。

write_short

public abstract void write_short(short value)
将一个 short 值写入此流。

参数:
value - 要写入的值。

write_ushort

public abstract void write_ushort(short value)
将一个无符号 short 值写入此流。

参数:
value - 要写入的值。

write_long

public abstract void write_long(int value)
将一个 CORBA long(即 Java int)值写入此流。

参数:
value - 要写入的值。

write_ulong

public abstract void write_ulong(int value)
将一个无符号 CORBA long(即 Java int)值写入此流。

参数:
value - 要写入的值。

write_longlong

public abstract void write_longlong(long value)
将一个 CORBA longlong(即 Java long)值写入此流。

参数:
value - 要写入的值。

write_ulonglong

public abstract void write_ulonglong(long value)
将一个无符号 CORBA longlong(即 Java long)值写入此流。

参数:
value - 要写入的值。

write_float

public abstract void write_float(float value)
将一个 float 值写入此流。

参数:
value - 要写入的值。

write_double

public abstract void write_double(double value)
将一个 double 值写入此流。

参数:
value - 要写入的值。

write_string

public abstract void write_string(String value)
将一个 string 值写入此流。

参数:
value - 要写入的值。

write_wstring

public abstract void write_wstring(String value)
将一个 wide string 值写入此流。

参数:
value - 要写入的值。

write_boolean_array

public abstract void write_boolean_array(boolean[] value,
                                         int offset,
                                         int length)
在此输出流上写入一个 boolean 数组。

参数:
value - 要写入的数组。
offset - 流中的偏移量。
length - 要写入的缓冲区长度。

write_char_array

public abstract void write_char_array(char[] value,
                                      int offset,
                                      int length)
在此输出流上写入一个 char 数组。

参数:
value - 要写入的数组。
offset - 流中的偏移量。
length - 要写入的缓冲区长度。

write_wchar_array

public abstract void write_wchar_array(char[] value,
                                       int offset,
                                       int length)
在此输出流上写入一个 wide char 数组。

参数:
value - 要写入的数组。
offset - 流中的偏移量。
length - 要写入的缓冲区长度。

write_octet_array

public abstract void write_octet_array(byte[] value,
                                       int offset,
                                       int length)
在此输出流上写入一个 CORBA 八位组 (byte) 数组。

参数:
value - 要写入的数组。
offset - 流中的偏移量。
length - 要写入的缓冲区长度。

write_short_array

public abstract void write_short_array(short[] value,
                                       int offset,
                                       int length)
在此输出流上写入一个 short 数组。

参数:
value - 要写入的数组。
offset - 流中的偏移量。
length - 要写入的缓冲区长度。

write_ushort_array

public abstract void write_ushort_array(short[] value,
                                        int offset,
                                        int length)
在此输出流上写入一个无符号 short 数组。

参数:
value - 要写入的数组。
offset - 流中的偏移量。
length - 要写入的缓冲区长度。

write_long_array

public abstract void write_long_array(int[] value,
                                      int offset,
                                      int length)
在此输出流上写入一个 CORBA long(即 Java int)数组。

参数:
value - 要写入的数组。
offset - 流中的偏移量。
length - 要写入的缓冲区长度。

write_ulong_array

public abstract void write_ulong_array(int[] value,
                                       int offset,
                                       int length)
在此输出流上写入一个无符号 CORBA long(即 Java int)数组。

参数:
value - 要写入的数组。
offset - 流中的偏移量。
length - 要写入的缓冲区长度。

write_longlong_array

public abstract void write_longlong_array(long[] value,
                                          int offset,
                                          int length)
在此输出流上写入一个 CORBA longlong(即 Java int)数组。

参数:
value - 要写入的数组。
offset - 流中的偏移量。
length - 要写入的缓冲区长度。

write_ulonglong_array

public abstract void write_ulonglong_array(long[] value,
                                           int offset,
                                           int length)
在此输出流上写入一个无符号 CORBA longlong(即 Java int)数组。

参数:
value - 要写入的数组。
offset - 流中的偏移量。
length - 要写入的缓冲区长度。

write_float_array

public abstract void write_float_array(float[] value,
                                       int offset,
                                       int length)
在此输入流上写入一个 float 数组。

参数:
value - 要写入的数组。
offset - 流中的偏移量。
length - 要写入的缓冲区长度。

write_double_array

public abstract void write_double_array(double[] value,
                                        int offset,
                                        int length)
在此输入流上写入一个 double 数组。

参数:
value - 要写入的数组。
offset - 流中的偏移量。
length - 要写入的缓冲区长度。

write_Object

public abstract void write_Object(Object value)
在此输入流上写入一个 CORBA Object。

参数:
value - 要写入的值。

write_TypeCode

public abstract void write_TypeCode(TypeCode value)
在此输出流上写入一个 TypeCode。

参数:
value - 要写入的值。

write_any

public abstract void write_any(Any value)
在此输出流上写入一个 Any。

参数:
value - 要写入的值。

write_Principal

@Deprecated
public void write_Principal(Principal value)
已过时。 已由 CORBA 2.2 取代。

在此输出流上写入一个 Principle。

参数:
value - 要写入的值。

write

public void write(int b)
           throws IOException
将一个 integer(数组长度)写入此流。

指定者:
OutputStream 中的 write
参数:
b - 要写入的值。
抛出:
IOException - 如果存在输入/输出错误
另请参见:
portable 包中有关未实现特性的注释

write_fixed

public void write_fixed(BigDecimal value)
写入一个 BigDecimal 数。

参数:
value - 要写入的值 BidDecimal。

write_Context

public void write_Context(Context ctx,
                          ContextList contexts)
在此流上写入一个 CORBA 上下文。该上下文被编组为一个 string 序列。实际上只写入那些在 contexts 参数中指定的 Context 值。

参数:
ctx - CORBA 上下文
contexts - ContextList 对象,包含要写入的 context 列表
另请参见:
portable 包中有关未实现特性的注释

orb

public ORB orb()
返回创建此 OutputStream 的 ORB。

返回:
返回创建此 OutputStream 的 ORB
另请参见:
portable 包中有关未实现特性的注释

JavaTM 2 Platform
Standard Ed. 6

提交错误或意见

版权所有 2008 Sun Microsystems, Inc. 保留所有权利。请遵守GNU General Public License, version 2 only