src/share/classes/org/omg/CORBA/ServiceInformationHolder.java

Thu, 31 Aug 2017 18:10:36 +0800

author
aoqi
date
Thu, 31 Aug 2017 18:10:36 +0800
changeset 748
6845b95cba6b
parent 158
91006f157c46
parent 0
7ef37b2cdcad
permissions
-rw-r--r--

merge

aoqi@0 1 /*
aoqi@0 2 * Copyright (c) 1998, 2001, Oracle and/or its affiliates. All rights reserved.
aoqi@0 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
aoqi@0 4 *
aoqi@0 5 * This code is free software; you can redistribute it and/or modify it
aoqi@0 6 * under the terms of the GNU General Public License version 2 only, as
aoqi@0 7 * published by the Free Software Foundation. Oracle designates this
aoqi@0 8 * particular file as subject to the "Classpath" exception as provided
aoqi@0 9 * by Oracle in the LICENSE file that accompanied this code.
aoqi@0 10 *
aoqi@0 11 * This code is distributed in the hope that it will be useful, but WITHOUT
aoqi@0 12 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
aoqi@0 13 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
aoqi@0 14 * version 2 for more details (a copy is included in the LICENSE file that
aoqi@0 15 * accompanied this code).
aoqi@0 16 *
aoqi@0 17 * You should have received a copy of the GNU General Public License version
aoqi@0 18 * 2 along with this work; if not, write to the Free Software Foundation,
aoqi@0 19 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
aoqi@0 20 *
aoqi@0 21 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
aoqi@0 22 * or visit www.oracle.com if you need additional information or have any
aoqi@0 23 * questions.
aoqi@0 24 */
aoqi@0 25
aoqi@0 26 package org.omg.CORBA;
aoqi@0 27
aoqi@0 28 /**
aoqi@0 29 * The Holder for <tt>ServiceInformation</tt>. For more information on
aoqi@0 30 * Holder files, see <a href="doc-files/generatedfiles.html#holder">
aoqi@0 31 * "Generated Files: Holder Files"</a>.<P>
aoqi@0 32 * A Holder class for a <code>ServiceInformation</code> object
aoqi@0 33 * that is used to store "out" and "inout" parameters in IDL methods.
aoqi@0 34 * If an IDL method signature has an IDL <code>xxx</code> as an "out"
aoqi@0 35 * or "inout" parameter, the programmer must pass an instance of
aoqi@0 36 * <code>ServiceInformationHolder</code> as the corresponding
aoqi@0 37 * parameter in the method invocation; for "inout" parameters, the programmer
aoqi@0 38 * must also fill the "in" value to be sent to the server.
aoqi@0 39 * Before the method invocation returns, the ORB will fill in the
aoqi@0 40 * value corresponding to the "out" value returned from the server.
aoqi@0 41 * <P>
aoqi@0 42 * If <code>myServiceInformationHolder</code> is an instance of <code>ServiceInformationHolder</code>,
aoqi@0 43 * the value stored in its <code>value</code> field can be accessed with
aoqi@0 44 * <code>myServiceInformationHolder.value</code>.
aoqi@0 45 */
aoqi@0 46 public final class ServiceInformationHolder
aoqi@0 47 implements org.omg.CORBA.portable.Streamable {
aoqi@0 48
aoqi@0 49 /**
aoqi@0 50 * The <code>ServiceInformation</code> value held by this
aoqi@0 51 * <code>ServiceInformationHolder</code> object in its <code>value</code> field.
aoqi@0 52 */
aoqi@0 53 public ServiceInformation value;
aoqi@0 54
aoqi@0 55 /**
aoqi@0 56 * Constructs a new <code>ServiceInformationHolder</code> object with its
aoqi@0 57 * <code>value</code> field initialized to null.
aoqi@0 58 */
aoqi@0 59 public ServiceInformationHolder() {
aoqi@0 60 this(null);
aoqi@0 61 }
aoqi@0 62
aoqi@0 63 /**
aoqi@0 64 * Constructs a new <code>ServiceInformationHolder</code> object with its
aoqi@0 65 * <code>value</code> field initialized to the given
aoqi@0 66 * <code>ServiceInformation</code> object.
aoqi@0 67 *
aoqi@0 68 * @param arg the <code>ServiceInformation</code> object with which to initialize
aoqi@0 69 * the <code>value</code> field of the newly-created
aoqi@0 70 * <code>ServiceInformationHolder</code> object
aoqi@0 71 */
aoqi@0 72 public ServiceInformationHolder(org.omg.CORBA.ServiceInformation arg) {
aoqi@0 73 value = arg;
aoqi@0 74 }
aoqi@0 75
aoqi@0 76
aoqi@0 77 /**
aoqi@0 78 * Marshals the value in this <code>ServiceInformationHolder</code> object's
aoqi@0 79 * <code>value</code> field to the output stream <code>out</code>.
aoqi@0 80 *
aoqi@0 81 * @param out the <code>OutputStream</code> object that will contain
aoqi@0 82 * the CDR formatted data
aoqi@0 83 */
aoqi@0 84 public void _write(org.omg.CORBA.portable.OutputStream out) {
aoqi@0 85 org.omg.CORBA.ServiceInformationHelper.write(out, value);
aoqi@0 86 }
aoqi@0 87
aoqi@0 88 /**
aoqi@0 89 * Reads unmarshalled data from the input stream <code>in</code> and assigns it to
aoqi@0 90 * the <code>value</code> field in this <code>ServiceInformationHolder</code> object.
aoqi@0 91 *
aoqi@0 92 * @param in the <code>InputStream</code> object containing CDR
aoqi@0 93 * formatted data from the wire
aoqi@0 94 */
aoqi@0 95 public void _read(org.omg.CORBA.portable.InputStream in) {
aoqi@0 96 value = org.omg.CORBA.ServiceInformationHelper.read(in);
aoqi@0 97 }
aoqi@0 98
aoqi@0 99 /**
aoqi@0 100 * Retrieves the <code>TypeCode</code> object that corresponds
aoqi@0 101 * to the value held in this <code>ServiceInformationHolder</code> object's
aoqi@0 102 * <code>value</code> field.
aoqi@0 103 *
aoqi@0 104 * @return the type code for the value held in this <code>ServiceInformationHolder</code>
aoqi@0 105 * object
aoqi@0 106 */
aoqi@0 107 public org.omg.CORBA.TypeCode _type() {
aoqi@0 108 return org.omg.CORBA.ServiceInformationHelper.type();
aoqi@0 109 }
aoqi@0 110 }

mercurial