Class RecurBDI


  • public class RecurBDI
    extends java.lang.Object
    Agent that has a goal for buying an amount of items.
    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
      class  RecurBDI.BuyItemsGoal
      A buy items goal that is responsible for buying a number of items.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected jadex.bridge.IInternalAccess agent
      The bdi agent.
      protected java.util.List<jadex.bdiv3.testcases.goals.RecurBDI.Item> items
      The list of items.
      protected double money
      The initial money.
      protected java.util.List<jadex.bdiv3.testcases.goals.RecurBDI.Item> store
      The items in store.
      protected jadex.base.test.TestReport tr  
    • Constructor Summary

      Constructors 
      Constructor Description
      RecurBDI()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void body()
      The agent body.
      protected jadex.commons.future.IFuture<java.lang.Void> buyItemPlan​(RecurBDI.BuyItemsGoal goal)
      First plan.
      void destroy​(jadex.bridge.IInternalAccess agent)
      Called when agent is killed.
      double getMoney()
      Get the money.
      void setMoney​(double money)
      Set the money.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • agent

        protected jadex.bridge.IInternalAccess agent
        The bdi agent.
      • items

        protected java.util.List<jadex.bdiv3.testcases.goals.RecurBDI.Item> items
        The list of items.
      • money

        protected double money
        The initial money.
      • store

        protected java.util.List<jadex.bdiv3.testcases.goals.RecurBDI.Item> store
        The items in store.
      • tr

        protected jadex.base.test.TestReport tr
    • Constructor Detail

      • RecurBDI

        public RecurBDI()
    • Method Detail

      • body

        public void body()
        The agent body.
      • destroy

        public void destroy​(jadex.bridge.IInternalAccess agent)
        Called when agent is killed.
      • buyItemPlan

        protected jadex.commons.future.IFuture<java.lang.Void> buyItemPlan​(RecurBDI.BuyItemsGoal goal)
        First plan. Fails with exception.
      • getMoney

        public double getMoney()
        Get the money.
        Returns:
        The money.
      • setMoney

        public void setMoney​(double money)
        Set the money.
        Parameters:
        money - The money to set.