2N/A * The contents of this file are subject to the terms of the 2N/A * Common Development and Distribution License (the "License"). 2N/A * You may not use this file except in compliance with the License. 2N/A * See the License for the specific language governing permissions 2N/A * and limitations under the License. 2N/A * When distributing Covered Code, include this CDDL HEADER in each 2N/A * If applicable, add the following below this CDDL HEADER, with the 2N/A * fields enclosed by brackets "[]" replaced with your own identifying 2N/A * information: Portions Copyright [yyyy] [name of copyright owner] 2N/A * Copyright (c) 1999 by Sun Microsystems, Inc. 2N/A * All rights reserved. 2N/A// Author: Erik Guttman 2N/A * The ServiceLocationManager class provides entry to SLP services. 2N/A * The ServiceLocationManager class uses static methods 2N/A * to provide objects encapsulating the connection with the Service 2N/A * Location facility. In addition, it provides access to known 2N/A * @author Erik Guttman 2N/A * The property accessor for the Locator object. If user agent 2N/A * functionality is not available, returns null. 2N/A * @param locale The Locale of the Locator object. Use null for default. 2N/A * @return The Locator object. 2N/A * @exception ServiceLocationException Thrown if the locator can't 2N/A * The property accessor for the Advertiser object. If service agent 2N/A * functionality is not available, returns null. 2N/A * @param locale The Locale of the Advertiser object. Use null for default. 2N/A * @return The Advertiser object. 2N/A * @exception ServiceLocationException Thrown if the locator can't 2N/A * Returns a vector of known scope names. It will include any 2N/A * scopes defined in the configuration file and ensure that the 2N/A * <i>order</i> of those scope strings is kept in the list of 2N/A * scopes which is returned. This method enforces the constraint 2N/A * that the default scope is returned if no other is available. 2N/A * @param typeHint Type to look for if SA advertisment required. 2N/A * @return Vector containing Strings with scope names. 2N/A // For the UA, return configured scopes if we have them. 2N/A // If no configured scopes, get discovered scopes from 2N/A // If still none, perform SA discovery. 2N/A // If still none, then return default scope. The client won`t 2N/A // be able to contact anyone because there`s nobody out there. 2N/A * Returns the maximum across all DAs of the min-refresh-interval 2N/A * attribute. This value satisfies the advertised refresh interval 2N/A * bounds for all DAs, and, if used by the SA, assures that no 2N/A * refresh registration will be rejected. If no DA advertises a 2N/A * min-refresh-interval attribute, a value of 0 is returned. 2N/A * @return The maximum min-refresh-interval attribute value. 2N/A // Get the min-refresh-interval attribute values for all DA's from 2N/A // We don't simply do Locator.findAttributes() here because we 2N/A // need to contact the SA server directly. 2N/A // Send it down the pipe to the IPC process. It's a bad bug 2N/A // if the reply comes back as not a CAttrMsg. 2N/A // Check error code. 2N/A // Sort through the attribute values to determine reply. 2N/A for (i =
0; i < n; i++) {
2N/A // Private implementation. 2N/A // Return the requested class, or null if it can't be found. 2N/A // Return an instance from the class. 2N/A // Perform SA discovery, since no DA scopes found. 2N/A // Get type hint if any. 2N/A for (i =
0; i < n; i++) {
2N/A // Add logical disjunction if more than one element. 2N/A // Form SA discovery request. 2N/A // Transact the advert request. 2N/A // DA table not needed... 2N/A // Initialize SLPConfig and DATable.