StringHolder.java revision 157
1178N/A * Copyright (c) 1995, 2001, Oracle and/or its affiliates. All rights reserved. 1178N/A * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 1178N/A * This code is free software; you can redistribute it and/or modify it 1178N/A * under the terms of the GNU General Public License version 2 only, as 1178N/A * published by the Free Software Foundation. Oracle designates this 1178N/A * particular file as subject to the "Classpath" exception as provided 1178N/A * by Oracle in the LICENSE file that accompanied this code. 1178N/A * This code is distributed in the hope that it will be useful, but WITHOUT 1178N/A * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 1178N/A * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 1178N/A * version 2 for more details (a copy is included in the LICENSE file that 1178N/A * You should have received a copy of the GNU General Public License version 2362N/A * 2 along with this work; if not, write to the Free Software Foundation, 2362N/A * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 1178N/A * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 1178N/A * or visit www.oracle.com if you need additional information or have any 1178N/A * The Holder for <tt>String</tt>. For more information on 1178N/A * "Generated Files: Holder Files"</a>.<P> 1178N/A * A Holder class for a <code>String</code> 1178N/A * that is used to store "out" and "inout" parameters in IDL operations. 1178N/A * If an IDL operation signature has an IDL <code>string</code> as an "out" 1178N/A * or "inout" parameter, the programmer must pass an instance of 1178N/A * <code>StringHolder</code> as the corresponding 1178N/A * parameter in the method invocation; for "inout" parameters, the programmer 1178N/A * must also fill the "in" value to be sent to the server. 1178N/A * Before the method invocation returns, the ORB will fill in the 1178N/A * value corresponding to the "out" value returned from the server. 1178N/A * If <code>myStringHolder</code> is an instance of <code>StringHolder</code>, 1178N/A * the value stored in its <code>value</code> field can be accessed with 1178N/A * <code>myStringHolder.value</code>. 1178N/A * The <code>String</code> value held by this <code>StringHolder</code> 1178N/A * Constructs a new <code>StringHolder</code> object with its 1178N/A * <code>value</code> field initialized to <code>null</code>. 1178N/A * Constructs a new <code>StringHolder</code> object with its 1178N/A * <code>value</code> field initialized to the given 1178N/A * @param initial the <code>String</code> with which to initialize 0N/A * the <code>value</code> field of the newly-created 1178N/A * <code>StringHolder</code> object 1178N/A * Reads the unmarshalled data from <code>input</code> and assigns it to 1178N/A * the <code>value</code> field of this <code>StringHolder</code> object. 1178N/A * @param input the InputStream containing CDR formatted data from the wire. 1178N/A * Marshals the value held by this <code>StringHolder</code> object 0N/A * to the output stream <code>output</code>. 0N/A * @param output the OutputStream which will contain the CDR formatted data. 0N/A * Retrieves the <code>TypeCode</code> object that corresponds to 0N/A * the value held in this <code>StringHolder</code> object. 0N/A * @return the type code of the value held in this <code>StringHolder</code>