Package cartago

Examples of cartago.ArtifactId


    boolean maximumReached = false;
 
   
    @Override
    public void action() {
      ArtifactId art = Role.createArtifact(ARTIFACT_NAME, CNPArtifact.class);
      initiator = (Initiator)(Role.enact(CNPArtifact.INITIATOR_ROLE, art, this, myAgent.getAID()));
     
      initiator.startObserving(this);
//      initiator.registerMethod(this, "listenerProposal");
//      logger.debug("Method registered.");
View Full Code Here


    Proposal p = null;
    Participant participant = null;
   
    @Override
    public void action() {
      ArtifactId art = Role.createArtifact(ARTIFACT_NAME, CNPArtifact.class);
      participant = (Participant)(Role.enact(CNPArtifact.PARTICIPANT_ROLE, art, this, myAgent.getAID()));
//      participant.registerMethod(this, "listenerCfp");
      participant.startObserving(this);
     
      // receiving task message: necessario pensare a cose simili a "performative", o quantomeno tipi di messaggio. Qui mi aspetto una proposta, dopo un risultato
View Full Code Here

    int maximumProposals = 3;
    boolean maximumReached = false;

    @Override
    public void action() {
      ArtifactId art = Role.createArtifact(ARTIFACT_NAME,
          CNPArtifact.class);
      initiator = (Initiator) (Role.enact(CNPArtifact.INITIATOR_ROLE,
          art, this, myAgent.getAID()));
     
     
View Full Code Here

    Proposal p = null;
    Participant participant = null;

    @Override
    public void action() {
      ArtifactId art = Role.createArtifact(ARTIFACT_NAME,
          CNPArtifact.class);
      participant = (Participant) (Role.enact(
          CNPArtifact.PARTICIPANT_ROLE, art, this, myAgent.getAID()));
      participant.startObserving(this);
    }
View Full Code Here

    testBlackboard();
  }
 
  private void testBlackboard() {
    try {
      ArtifactId blackboard = lookupArtifact("blackboard");
      logger.debug("Artifact blackboard retrieved.");
//      try {
//        doAction(blackboard, new Op(OUT, "provaFatto", new Fact("provaFattoIntero", 1)));
//      } catch (MissingOperandException e) {
//        // TODO Auto-generated catch block
View Full Code Here

    boolean maximumReached = false;
 
   
    @Override
    public void action() {
      ArtifactId art = Role.createArtifact(ARTIFACT_NAME, CNPArtifact.class);
      initiator = (Initiator)(Role.enact(CNPArtifact.INITIATOR_ROLE, art, this, myAgent.getAID()));
     
      try {
        // wait from participants
        Thread.sleep(5000);
View Full Code Here

    Proposal p = null;
    Participant participant = null;
   
    @Override
    public void action() {
      ArtifactId art = Role.createArtifact(ARTIFACT_NAME, CNPArtifact.class);
      participant = (Participant)(Role.enact(CNPArtifact.PARTICIPANT_ROLE, art, this, myAgent.getAID()));
//      participant.registerMethod(this, "listenerCfp");
      participant.startObserving(this);
     
      // receiving task message: necessario pensare a cose simili a "performative", o quantomeno tipi di messaggio. Qui mi aspetto una proposta, dopo un risultato
View Full Code Here

    Proposal p = null;
    Participant participant = null;

    @Override
    public void action() {
      ArtifactId art = Role.createArtifact(ARTIFACT_NAME,
          CNPArtifact.class);
      participant = (Participant) (Role.enact(
          CNPArtifact.PARTICIPANT_ROLE, art, this, myAgent.getAID()));

      //
View Full Code Here

    Proposal p = null;
    Participant participant = null;

    @Override
    public void action() {
      ArtifactId art = Role.createArtifact(ARTIFACT_NAME,
          CNPArtifact.class);
      participant = (Participant) (Role.enact(
          CNPArtifact.PARTICIPANT_ROLE, art, this, myAgent.getAID()));
      participant.startObserving(this);
    }
View Full Code Here

  protected void setup() {
    addBehaviour(new OneShotBehaviour() {
     
      @Override
      public void action() {
        ArtifactId art = Role.createArtifact(ARTIFACT_NAME, CommunicationArtifactImpl.class);
        CARole user = (CARole)(Role.enact(CommunicationArtifact.CA_ROLE, art, this, myAgent.getAID()));
        RoleId receiver = new RoleId(CommunicationArtifact.CA_ROLE, RoleId.GENERIC_ROLE);
        try {
          Thread.sleep(1000);
        } catch (InterruptedException e) {
View Full Code Here

TOP

Related Classes of cartago.ArtifactId

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.