Package jade.domain
Class FIPAException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- jade.domain.FIPAException
-
- All Implemented Interfaces:
ContentElement,Predicate,Serializable,Serializable
- Direct Known Subclasses:
FailureException,NotUnderstoodException,RefuseException
public class FIPAException extends Exception implements Predicate
This class represents a generic FIPAException, i.e. one of NotUnderstood,Failure,Refuse, as defined injade.domain.FIPAAgentManagement. It has two constructors, one based on an ACLMessage, and the second based on its content, i.e. the exception message.- Version:
- $Date$ $Revision$
- Author:
- Giovanni Rimassa - Universita' di Parma
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected ACLMessagemsg
-
Constructor Summary
Constructors Constructor Description FIPAException(ACLMessage message)Constructs aFIPAExceptionfrom the given ACL message.FIPAException(String message)Constructs a genericFIPAException.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ACLMessagegetACLMessage()Retrieve the ACL message whose content is represented by this exception.StringgetMessage()Get the content of the ACL message representing this exceptionprotected voidsetMessage(String message)Set the content of the ACL message representing this exception-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
-
-
-
Field Detail
-
msg
protected ACLMessage msg
-
-
Constructor Detail
-
FIPAException
public FIPAException(String message)
Constructs a genericFIPAException. The ACL message performative is defaulted tonot-understood.- Parameters:
message- is the content of the ACLMessage
-
FIPAException
public FIPAException(ACLMessage message)
Constructs aFIPAExceptionfrom the given ACL message.- Parameters:
message- is the ACL message representing this exception
-
-
Method Detail
-
getACLMessage
public ACLMessage getACLMessage()
Retrieve the ACL message whose content is represented by this exception.- Returns:
- the ACLMessage representing this exception
-
setMessage
protected void setMessage(String message)
Set the content of the ACL message representing this exception- Parameters:
message- is the content
-
getMessage
public String getMessage()
Get the content of the ACL message representing this exception- Overrides:
getMessagein classThrowable- Returns:
- A string representing the message content that describes this FIPA exception.
-
-