net.sf.adf.acl
Class StringCodec

java.lang.Object
  extended by net.sf.adf.acl.StringCodec
All Implemented Interfaces:
ACLCodec

public class StringCodec
extends java.lang.Object
implements ACLCodec

Author:
Catalin Hritcu

Constructor Summary
StringCodec()
           
 
Method Summary
 ACLMessage decode(java.lang.String str)
          Decodes .
 AID decodeAID(java.lang.String str)
           
 java.lang.String encode(ACLMessage message)
          Encodes an ACLMessage and returns the resulting String.
 java.lang.String encode(AID aid)
           
 java.lang.String getMimeType()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StringCodec

public StringCodec()
Method Detail

decode

public ACLMessage decode(java.lang.String str)
                  throws DecodingException
Description copied from interface: ACLCodec
Decodes .

Specified by:
decode in interface ACLCodec
Parameters:
str - A String representation of an ACLMessage
Returns:
The ACLMessage represented by str
Throws:
DecodingException - For some reason the String could not be decoded.

decodeAID

public AID decodeAID(java.lang.String str)
              throws DecodingException
Throws:
DecodingException

encode

public java.lang.String encode(ACLMessage message)
Description copied from interface: ACLCodec
Encodes an ACLMessage and returns the resulting String.

Specified by:
encode in interface ACLCodec
Parameters:
message - The ACLMessage to be encoded.
Returns:
A textual representation of the message

encode

public java.lang.String encode(AID aid)

getMimeType

public java.lang.String getMimeType()
Specified by:
getMimeType in interface ACLCodec