Subject: Re: [jade-develop] question
From: Katia Abi Fadel (kabifade@enst.fr)
Date: Thu Sep 19 2002 - 11:53:41 MET DST
Hi all,
Thank you, but I've resolved this problem.
Katia.
Ignazio Pi wrote:
>Hi,
>is the receive() included in a cyclic behaviour, or anyway is that executed
>more than just once?
>bye!
>----- Original Message -----
>From: "Katia Abi Fadel" <kabifade@enst.fr>
>To: <jade-develop@sharon.cselt.it>
>Sent: Tuesday, September 17, 2002 2:46 PM
>Subject: [jade-develop] question
>
>
>
>
>>Hi,
>>
>> I'm trying to create agents that are able to communicate between
>>them. Just like the testagent examples created by LEAP, I want thanks to
>>the gui interface to be able to choose whether I want to send a message,
>>and when received to reply or not.
>>So I defined 2 classes one to send messages in which I define the
>>message as follows:
>> ACLMessage msg = new
>>ACLMessage(ACLMessage.INFORM);
>> msg.setContent("COURS");
>>
>>This class is working properly.
>>One to reply with a message, so I use:
>> MessageTemplate m1 =
>>MessageTemplate.MatchPerformative(ACLMessage.INFORM);
>> ACLMessage m = receive(m1);
>> if (m != null)
>> {................}
>>
>>However m is always null. Could you please tell me what is wrong?!
>>Thank you.
>>Katia.
>>
>>
>>_______________________________________________
>>jade-develop mailing list
>>jade-develop@sharon.cselt.it
>>http://sharon.cselt.it/mailman/listinfo/jade-develop
>>UNSUBSCRIBE INSTRUCTIONS AT http://jade.cselt.it/mailing.htm#unsubscribe
>>
>>
>>
>
>
>
>
Hi, is the receive() included in a cyclic behaviour, or anyway is that executed more than just once? bye! ----- Original Message ----- From: "Katia Abi Fadel" <kabifade@enst.fr> To: <jade-develop@sharon.cselt.it> Sent: Tuesday, September 17, 2002 2:46 PM Subject: [jade-develop] questionHi, I'm trying to create agents that are able to communicate between them. Just like the testagent examples created by LEAP, I want thanks to the gui interface to be able to choose whether I want to send a message, and when received to reply or not. So I defined 2 classes one to send messages in which I define the message as follows: ACLMessage msg = new ACLMessage(ACLMessage.INFORM); msg.setContent("COURS"); This class is working properly. One to reply with a message, so I use: MessageTemplate m1 = MessageTemplate.MatchPerformative(ACLMessage.INFORM); ACLMessage m = receive(m1); if (m != null) {................} However m is always null. Could you please tell me what is wrong?! Thank you. Katia. _______________________________________________ jade-develop mailing list jade-develop@sharon.cselt.it http://sharon.cselt.it/mailman/listinfo/jade-develop UNSUBSCRIBE INSTRUCTIONS AT http://jade.cselt.it/mailing.htm#unsubscribe
This archive was generated by hypermail 2a22 : Mon Sep 23 2002 - 18:24:51 MET DST