com.artima.place
Class URLLink

java.lang.Object
  |
  +--com.artima.place.URLLink
All Implemented Interfaces:
Link, java.io.Serializable

public final class URLLink
extends java.lang.Object
implements Link

Represents a URL-based link to a service on the network.

See Also:
Serialized Form

Constructor Summary
URLLink(URLString url)
          Construct a URLLink with a URLString.
URLLink(URLString[] urls)
          Construct a URLLink with an array of URLStrings.
 
Method Summary
 LinkActivation activate(ActivationClient client)
          Invokes activationSucceeded() on the passed ActivationClient, passing to activationSucceeded() a ServiceItem that contains a URLFactory service and null references for the ServiceID and attributes set (the Entry array).
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

URLLink

public URLLink(URLString url)
Construct a URLLink with a URLString.
Parameters:
url - the URL to be contained in the URLFactory produced when this link is activated.
Throws:
NullPointerException - if passed url reference is null

URLLink

public URLLink(URLString[] urls)
Construct a URLLink with an array of URLStrings.
Parameters:
urls - the URLs, in order, to be contained in the URLFactory produced when this link is activated.
Throws:
NullPointerException - if passed urls array is null
java.lang.IllegalArgumentException - if passed urls array is empty
Method Detail

activate

public LinkActivation activate(ActivationClient client)
Invokes activationSucceeded() on the passed ActivationClient, passing to activationSucceeded() a ServiceItem that contains a URLFactory service and null references for the ServiceID and attributes set (the Entry array).
Specified by:
activate in interface Link
Parameters:
client - the ActivationClient that will notified when this link activation completes
Returns:
the LinkActivation object with which the client can interact with this activation of this link.
Throws:
NullPointerException - if passed client is null