public interface CodecOperations 
      Codec提供了一种将这些组件在其IDL数据类型及其CDR封装表示之间传输的机制。 
        A Codec是从CodecFactory获得的。 CodecFactory是通过电话ORB.resolve_initial_references( "CodecFactory" ) 。 
| Modifier and Type | Method and Description | 
|---|---|
| Any | decode_value(byte[] data, TypeCode tc)
              根据给定的 
              TypeCode和对这个Codec的编码格式,将给定的字节数组解码为Codec。 | 
| Any | decode(byte[] data)
              基于对该 
              Codec的编码格式,将给定的字节数组解码为Codec。 | 
| byte[] | encode_value(Any data)
              基于对该编解码器有效的编码格式,将给定的任何数据转换为字节数组。 
             | 
| byte[] | encode(Any data)
              根据为此 
              Codec的编码格式,将给定的任何值转换为字节数组。 | 
byte[] encode(Any data) throws InvalidTypeForEncoding
Codec 。 
          data - 以任何形式编码为字节数组的数据。 
           TypeCode和类型的数据。 
           InvalidTypeForEncoding - 如果该类型对于此 
            Codec有效的编码格式无效,则 
            Codec 。 
           Any decode(byte[] data) throws FormatMismatch
Codec的编码格式,将给定的字节数组解码为 
           Codec 。 
          data - 以字节数组的形式将要解码为Any的数据。 
           FormatMismatch - 如果字节数组不能解码成 
            FormatMismatch ,则抛出。 
           byte[] encode_value(Any data) throws InvalidTypeForEncoding
TypeCode 。 
          data - 将要编码为字节数组的以Any形式的数据。 
           InvalidTypeForEncoding - 如果该类型对于Codec有效的编码格式无效,则 
            Codec 。 
           Any decode_value(byte[] data, TypeCode tc) throws FormatMismatch, TypeMismatch
TypeCode和对该 
           TypeCode的编码格式,将给定的字节数组解码为 
           Codec 。 
          data - 以字节数组的形式将要解码为Any的数据。 
           tc - 用于解码数据的TypeCode。 
           FormatMismatch - 如果字节数组不能解码成Any,则抛出。 
           TypeMismatch 
            Submit a bug or feature 
For further API reference and developer documentation, see Java SE Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.
 Copyright © 1993, 2014, Oracle and/or its affiliates. All rights reserved.