Date: March 29, 2001
Java platform: Sun JDK 1.2 Linux
JADE version 2.2
Since JADE 2.2, FIPA-ACL Message codecs can be plugged and activated via the command line on any JADE container. By default, the platform uses a String ACL codec However, Bit-efficient codec can be used as an alternative FIPA-ACL encoding. This tutorial describes how to install and use the the bit-efficient ACL codec with JADE. The bit-efficient ACL codec is implementation of experimental FIPA standard number 00069 (FIPA ACL Message Representation in Bit-Efficient Specification).
Here is an example of how you would start the platform assuming you
are in the root of the Jade directory:
java -classpath ./lib/jade.jar:./lib/jadeTools.jar:./lib/iiop.jar:./add-ons/BEFipaMessage/lib/BEFipaMessage.jar
jade.Boot -aclcodec sonera.fipa.acl.BitEffACLCodec (for Unix)
or
java -classpath ./lib/jade.jar;./lib/jadeTools.jar;./lib/iiop.jar;./add-ons/BEFipaMessage/lib/BEFipaMessage.jar
jade.Boot -aclcodec sonera.fipa.acl.BitEffACLCodec (for Windows)
More aclcodecs can be indicated separated by a ';'
e.setAclRepresentation("fipa.acl.rep.bitefficient.std");
and Jade takes care of the rest. When receiving bit-efficiently encoded messages, the agent does not have to do anything, Jade is working for him.
java DummyEncoder < test.msg > be.msg
encodes these messages to file be.msg. (Notice that BEFipaMessage.jar and jade.jar must be added to the classpath).
Similarly, the DummyDecoder reads bit-efficiently encoded messages from standard input and writes the messages to standard output using string-based encoding. For example,
java DummyDecoder < be.msg > new.msg
writes the messages to file new.msg. The contents of test.msg and new.msg should be the same. However, this is not necessarily true.e The number of white space might be different as well as the order of message parameters (if new.msg is encoded and decoded again, then the new result should be exactly the same).
By default, these applications does not use dynamic codetable. However, it is possible to give an additional command line parameter to each of these programs that defines the size of the code table. For example:
java DummyEncoder 9 < test.msg > be.msg
and
java DummyDecoder 9 < be.msg > new.msg
In the example above, code table size 9 is used (i.e., 2^9 entries in the code table). The size must be between 8 and 16. Notice that exactly same code table size must be given to both applications, otherwise decoding fails.
JADE
is a trademark of
CSELT. JADE
has been developed jointly by CSELT and
the Computer Engineering Group of
the University of Parma.
The BE-ACL codec implementation was
developed by Sonera Corporation.