ADK CVS

tryllian.are.persistence.spi
Interface AgentBuilder


public interface AgentBuilder

The AgentBuilder is an interface by which plugins can reconstruct agents without having to know about the internal structure of agents.


Field Summary
static java.lang.String CATEGORY_RUNTIME
          The category for runtime attributes
static java.lang.String CATEGORY_STATISTICAL
          The category for statistical attributes
static java.lang.String TYPE_BINARY
          The type for binary serialization
static java.lang.String TYPE_LOGICAL
          The type for logical serialization
 
Method Summary
 ARLBuilder getARL()
          The AgentBuilder implementation creates an instance of the ARLBuilder implementation for the plugins to use: the plugin cannot do that.
 void setAgent(byte[] agent)
          Sets the byte array containing the storable data of an agent.
 void setAgent(java.lang.String agent)
          Sets the string containing the storable data of an agent.
 void setAgentAttributes(java.util.Map map, java.lang.String category)
          Sets the agent's attributes in the form of a map containing key-value pair combinations.
 void setAgentID(java.lang.String agentID)
          Sets the AgentID.
 void setARL(ARLBuilder builder)
          Returns the AgentResourceLocator Builder which represents the current agent's AgentResourceLocator.
 void setSerializationType(java.lang.String type)
          Sets the serialization type of this agent: TYPE_BINARY or TYPE_LOGICAL.
 

Field Detail

CATEGORY_RUNTIME

public static final java.lang.String CATEGORY_RUNTIME
The category for runtime attributes

See Also:
Constant Field Values

CATEGORY_STATISTICAL

public static final java.lang.String CATEGORY_STATISTICAL
The category for statistical attributes

See Also:
Constant Field Values

TYPE_BINARY

public static final java.lang.String TYPE_BINARY
The type for binary serialization

See Also:
Constant Field Values

TYPE_LOGICAL

public static final java.lang.String TYPE_LOGICAL
The type for logical serialization

See Also:
Constant Field Values
Method Detail

setAgent

public void setAgent(java.lang.String agent)
Sets the string containing the storable data of an agent.

Parameters:
agent - the agent encoded as a string

setAgent

public void setAgent(byte[] agent)
Sets the byte array containing the storable data of an agent.

Parameters:
agent - the agent encoded as a string

setAgentID

public void setAgentID(java.lang.String agentID)
Sets the AgentID.

Parameters:
agentID - The agentID encoded as a string

setAgentAttributes

public void setAgentAttributes(java.util.Map map,
                               java.lang.String category)
Sets the agent's attributes in the form of a map containing key-value pair combinations. Key and value are both strings.

Parameters:
map - a (String, String) Map.

setSerializationType

public void setSerializationType(java.lang.String type)
Sets the serialization type of this agent: TYPE_BINARY or TYPE_LOGICAL.

Parameters:
type - a string either TYPE_LOGICAL or TYPE_BINARY

setARL

public void setARL(ARLBuilder builder)
Returns the AgentResourceLocator Builder which represents the current agent's AgentResourceLocator. This can be used by the plugin to describe the related Agent Resource Locator

Parameters:
builder - the ARLBuilder related to this agent.

getARL

public ARLBuilder getARL()
The AgentBuilder implementation creates an instance of the ARLBuilder implementation for the plugins to use: the plugin cannot do that.

Returns:
The arlbuilder implementation this agentbuilder has created.

Copyright 2005, Tryllian Solutions B.V.