public final class AnyHolder extends Object implements Streamable
 用于在IDL方法中存储“out”和“inout”参数的Any对象的持有者类。 如果IDL方法签名具有IDL any作为“out”或“inout”参数,则程序员必须传递一个AnyHolder的实例作为方法调用中的相应参数; 对于“inout”参数,程序员还必须填写要发送到服务器的“in”值。 在方法调用返回之前,ORB将填写与从服务器返回的“out”值对应的值。 
 如果myAnyHolder是实例AnyHolder ,存储在其值value字段可以与被访问myAnyHolder.value 。 
| Modifier and Type | Field and Description | 
|---|---|
| Any | valueAny所持AnyHolder这个价值AnyHolder对象。 | 
| Constructor and Description | 
|---|
| AnyHolder()
              构造一个新的 
              AnyHolder对象,其value字段初始化为null。 | 
| AnyHolder(Any initial)
              构造一个新 
              AnyHolder给定对象Any对象。 | 
| Modifier and Type | Method and Description | 
|---|---|
| void | _read(InputStream input)
              从 
              input读取,并通过未编组的数据启动持有人的值。 | 
| TypeCode | _type()
              返回对应于该 
              TypeCode对象中保存的值的AnyHolder对象。 | 
| void | _write(OutputStream output)
              在 
              AnyHolder对象的output的值。 | 
public Any value
Any价值由本 
           AnyHolder持有。 
          public AnyHolder()
AnyHolder对象,其 
           value字段初始化为 
           null 。 
          public AnyHolder(Any initial)
AnyHolder给定对象 
           Any对象。 
          initial - 
            Any对象,用于初始化新的 
            AnyHolder对象的 
            value字段 
           public void _read(InputStream input)
input读取,并通过未编组的数据激活持有人的价值。 
          _read在界面 
            Streamable 
           input - 包含来自电线的CDR格式数据的InputStream。 
           public void _write(OutputStream output)
AnyHolder对象的 
           output的值。 
          _write在界面 
            Streamable 
           output - 将包含CDR格式数据的OutputStream。 
           public TypeCode _type()
TypeCode对象中保存的值的 
           AnyHolder对象。 
          _type在接口 
            Streamable 
           AnyHolder对象中的TypeCode 
            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.