fipaos.ont.fipa.fipaman
Class APDescription


public class APDescription
implements Serializable

This class represents the Agent Platform Description object and contains a APTDescription which represents the Agent Platform Transport Description object
TODO: there is at present to checking to see if the characters in the fields are valid as per the BNF definitions




Constructor Summary
APDescription()
          This constructor creates an empty Agent Platform Descriptioon.
APDescription(String description)
          This constructor creates an APDescriptoin from a string.
APDescription(Content ap_content)
          This constructor takes a Content object as a parameter.

Method Summary
 booleanaddMTPD(MTPDescription mtpd)
          Adds a MTPDescription to the list of MTPDs
 BooleangetDynamic()
          Get the dynamic registration capability of the platform
 BooleangetMobility()
          Get the mobility capability of the platform
 SetgetMTPDs()
          Get the Agent Transport Description
 StringgetName()
          Get the name of the AP
 APTDescriptiongetTransportDescription()
          This method returns the transport profile of the Agent Platform.
 static voidmain(String[] args)
          This main method is used for testing.
 booleanremoveMTPD(MTPDescription mtpd)
          remove a Message Transport Protocol Description from the list
 voidsetDynamic(Boolean dynamic)
          Set whether the platform supports dynamic registration of Agents
 voidsetMobility(Boolean mobility)
          Set whether the platform supports mobility of the AP
 voidsetMTPDs(Set transport_description)
          Set the description MTPDescription capabilities of the AP
 voidsetName(String name)
          This method sets the name of the Agent Platform Description.
 voidsetTransportDescription(APTDescription transport_description)
          This method sets the transport profile of the Agent Platform
 StringtoString()
          A string representation of this APDescription

Constructor Detail

APDescription

public APDescription()
This constructor creates an empty Agent Platform Descriptioon.

APDescription

public APDescription(String description)
throws fipaos.parser.ParserException
This constructor creates an APDescriptoin from a string.
Parameters:
description - string representation of an APDescription
Throws:
ParserException - if it does not parse correctly

APDescription

public APDescription(Content ap_content)
throws fipaos.parser.ParserException
This constructor takes a Content object as a parameter.
Parameters:
ap_content - Content object created by the fipao.parser.sl.SLParser
Throws:
ParserException - if the String is invalid
Method Detail

addMTPD

public boolean addMTPD(MTPDescription mtpd)
Adds a MTPDescription to the list of MTPDs
Parameters:
mtpd - The MTPD to be added to the list
Returns: as per MTPDescription.addMTPD

getDynamic

public Boolean getDynamic()
Get the dynamic registration capability of the platform
Returns: true if the platform supports dynamic registration capability - false if not

getMobility

public Boolean getMobility()
Get the mobility capability of the platform
Returns: true if the platform supports mobility

getMTPDs

public Set getMTPDs()
Get the Agent Transport Description
Returns: the Agent Transport Description

getName

public String getName()
Get the name of the AP
Returns: the name of the AP

getTransportDescription

public APTDescription getTransportDescription()
This method returns the transport profile of the Agent Platform.
Returns: transport profile of the AP

main

public static void main(String[] args)
This main method is used for testing.
Parameters:
args - Arguments

removeMTPD

public boolean removeMTPD(MTPDescription mtpd)
remove a Message Transport Protocol Description from the list
Parameters:
mtpd - the MTPD that needs to be removed
Returns: as per the MTPDescription.removeMTPD()

setDynamic

public void setDynamic(Boolean dynamic)
Set whether the platform supports dynamic registration of Agents
Parameters:
dynamic - true if the platform supports dynamic registration

setMobility

public void setMobility(Boolean mobility)
Set whether the platform supports mobility of the AP
Parameters:
mobility - set to true if the agent platform supports mobility

setMTPDs

public void setMTPDs(Set transport_description)
Set the description MTPDescription capabilities of the AP
Parameters:
transport_description - the agent transport description object

setName

public void setName(String name)
This method sets the name of the Agent Platform Description.
Parameters:
name - The name of the AP

setTransportDescription

public void setTransportDescription(APTDescription transport_description)
This method sets the transport profile of the Agent Platform
Parameters:
transport_description - Transport Profile

toString

public String toString()
A string representation of this APDescription
Returns: A string representation of this APDescription

Association Links

to Class java.lang.String

The name of the AP

to Class java.lang.Boolean

The support for dynamic registration of the AP(optional)

to Class java.lang.Boolean

The support for mobility of the AP (optional)

to Class fipaos.ont.fipa.fipaman.APTDescription

The description MTS capabilities of the AP (optional