Lines Matching refs:name
35 * the <code>Naming</code> class takes as one of its arguments a name that
40 * //host:port/name
45 * accepts calls, and where <code>name</code> is a simple string uninterpreted
51 * <P><em>Binding</em> a name for a remote object is associating or
52 * registering a name for a remote object that can be used at a later time to
53 * look up that remote object. A remote object can be associated with a name
59 * object by name, obtain its reference, and then invoke remote methods on the
80 * with the specified <code>name</code>.
82 * @param name a name in URL format (without the scheme component)
84 * @exception NotBoundException if name is not currently bound
87 * @exception MalformedURLException if the name is not an appropriately
91 public static Remote lookup(String name)
96 ParsedNamingURL parsed = parseURL(name);
99 if (parsed.name == null)
101 return registry.lookup(parsed.name);
105 * Binds the specified <code>name</code> to a remote object.
107 * @param name a name in URL format (without the scheme component)
109 * @exception AlreadyBoundException if name is already bound
110 * @exception MalformedURLException if the name is not an appropriately
117 public static void bind(String name, Remote obj)
122 ParsedNamingURL parsed = parseURL(name);
128 registry.bind(parsed.name, obj);
132 * Destroys the binding for the specified name that is associated
135 * @param name a name in URL format (without the scheme component)
136 * @exception NotBoundException if name is not currently bound
137 * @exception MalformedURLException if the name is not an appropriately
144 public static void unbind(String name)
149 ParsedNamingURL parsed = parseURL(name);
152 registry.unbind(parsed.name);
156 * Rebinds the specified name to a new remote object. Any existing
157 * binding for the name is replaced.
159 * @param name a name in URL format (without the scheme component)
160 * @param obj new remote object to associate with the name
161 * @exception MalformedURLException if the name is not an appropriately
168 public static void rebind(String name, Remote obj)
171 ParsedNamingURL parsed = parseURL(name);
177 registry.rebind(parsed.name, obj);
186 * @param name a registry name in URL format (without the scheme
190 * @exception MalformedURLException if the name is not an appropriately
195 public static String[] list(String name)
198 ParsedNamingURL parsed = parseURL(name);
226 * object name.
280 "invalid character, '#', in URL name: " + str);
283 "invalid character, '?', in URL name: " + str);
293 String name = uri.getPath();
294 if (name != null) {
295 if (name.startsWith("/")) {
296 name = name.substring(1);
298 if (name.length() == 0) {
299 name = null;
339 return new ParsedNamingURL(host, port, name);
348 String name;
350 ParsedNamingURL(String host, int port, String name) {
353 this.name = name;