org.iids.aos.api
Class AgentScapeApiHelper

java.lang.Object
  extended by org.iids.aos.api.AgentScapeApiHelper

public final class AgentScapeApiHelper
extends java.lang.Object

AgentScapeApiHelper.

This is the AgentScapeApiHelper that helps to contact an AgentScape instance. It will return an AgentScapeApi which can be used to talk to AgentScape. The API is the only entry point for software (and agent) developers to interact with a running AgentScape platform. It exposes calls to create and manipulate (running) agents, and to use the AgentScape messaging and migration primitives. Moreover, any services that the running AgentScape platform offers have to be accessed through this interface.

Author:
rjtimmer, michel

Method Summary
static AgentScapeApi getAgentScapeClient()
          Obtain an instance of the AgentScape API.
static AgentScapeApi getAgentScapeClient(java.lang.String host)
           
static void reset()
          If we were bound to an API, but for some reason the host shut down, then use reset() to re-initialize the agent scape client.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getAgentScapeClient

public static final AgentScapeApi getAgentScapeClient()
Obtain an instance of the AgentScape API. This API can be used to invoke methods on a locally running AgentScape platform.

If multiple platforms are running (multiple APIs are published) then it is undefined to which running instance this API is bound. TODO!

Returns:
A reference to a locally running AgentScape API.

getAgentScapeClient

public static final AgentScapeApi getAgentScapeClient(java.lang.String host)

reset

public static void reset()
If we were bound to an API, but for some reason the host shut down, then use reset() to re-initialize the agent scape client.

Note: usually the error is received from some party performing a method call on the API. Usually the call itself will fail (and not just the call to {#getAgentScapeClient}. It is up to the application to decide whether the connection should be reset!



Copyright © 2003, 2004 IIDS Group. All Rights Reserved.