157N/A * Copyright (c) 1996, 1999, Oracle and/or its affiliates. All rights reserved. 0N/A * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 0N/A * This code is free software; you can redistribute it and/or modify it 0N/A * under the terms of the GNU General Public License version 2 only, as 157N/A * published by the Free Software Foundation. Oracle designates this 0N/A * particular file as subject to the "Classpath" exception as provided 157N/A * by Oracle in the LICENSE file that accompanied this code. 0N/A * This code is distributed in the hope that it will be useful, but WITHOUT 0N/A * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 0N/A * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 0N/A * version 2 for more details (a copy is included in the LICENSE file that 0N/A * accompanied this code). 0N/A * You should have received a copy of the GNU General Public License version 0N/A * 2 along with this work; if not, write to the Free Software Foundation, 0N/A * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 157N/A * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 157N/A * or visit www.oracle.com if you need additional information or have any 0N/A * An object containing a modifiable list of <code>String</code> objects 0N/A * that represent property names. 0N/A * This class is used in <code>Request</code> operations to 0N/A * describe the contexts that need to be resolved and sent with the 0N/A * invocation. (A context is resolved by giving a property name 0N/A * and getting back the value associated with it.) This is done 0N/A * by calling the <code>Context</code> method 0N/A * <code>get_values</code> and supplying a string from a 0N/A * <code>ContextList</code> object as the third parameter. 0N/A * The method <code>get_values</code> returns an <code>NVList</code> 0N/A * object containing the <code>NamedValue</code> objects that hold 0N/A * the value(s) identified by the given string. 0N/A * A <code>ContextList</code> object is created by the ORB, as 0N/A * org.omg.CORBA.ContextList ctxList = orb.create_context_list(); 0N/A * The variable <code>ctxList</code> represents an empty 0N/A * <code>ContextList</code> object. Strings are added to 0N/A * the list with the method <code>add</code>, accessed 0N/A * with the method <code>item</code>, and removed with the 0N/A * method <code>remove</code>. 0N/A * Returns the number of <code>String</code> objects in this 0N/A * <code>ContextList</code> object. 0N/A * @return an <code>int</code> representing the number of 0N/A * <code>String</code>s in this <code>ContextList</code> object 0N/A * Adds a <code>String</code> object to this <code>ContextList</code> 0N/A * @param ctx the <code>String</code> object to be added 0N/A * Returns the <code>String</code> object at the given index. 0N/A * @param index the index of the string desired, with 0 being the 0N/A index of the first string 0N/A * @return the string at the given index 0N/A * @exception org.omg.CORBA.Bounds if the index is greater than 0N/A * or equal to the number of strings in this 0N/A * <code>ContextList</code> object 0N/A * Removes the <code>String</code> object at the given index. Note that 0N/A * the indices of all strings following the one removed are 0N/A * shifted down by one. 0N/A * @param index the index of the <code>String</code> object to be removed, 0N/A * with 0 designating the first string 0N/A * @exception org.omg.CORBA.Bounds if the index is greater than 0N/A * or equal to the number of <code>String</code> objects in 0N/A * this <code>ContextList</code> object