Class TranslationBDI


  • public class TranslationBDI
    extends java.lang.Object

    TranslationAgent: Lesson G1.

    Using a separate thread to accept http connections.

    Explanation

    The agent opens a server connection at port 9199 and waits for translation requests.
    Direct your browser to e.g. http://localhost:9199/dog to perform a translation.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected jadex.bridge.IInternalAccess agent  
      protected jadex.bdiv3.features.IBDIAgentFeature bdiFeature  
      protected jadex.bridge.component.IExecutionFeature execFeature  
      protected java.net.ServerSocket server
      The server socket.
      protected java.util.Map<java.lang.String,​java.lang.String> wordtable
      The wordtable.
    • Constructor Summary

      Constructors 
      Constructor Description
      TranslationBDI()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void init()  
      void killed()
      Called when the agent is terminated.
      void translate​(TranslationBDI.Translate trans)
      Plan that translates a request.
      • Methods inherited from class java.lang.Object

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

      • execFeature

        protected jadex.bridge.component.IExecutionFeature execFeature
      • bdiFeature

        protected jadex.bdiv3.features.IBDIAgentFeature bdiFeature
      • agent

        protected jadex.bridge.IInternalAccess agent
      • wordtable

        protected java.util.Map<java.lang.String,​java.lang.String> wordtable
        The wordtable.
      • server

        protected java.net.ServerSocket server
        The server socket.
    • Constructor Detail

      • TranslationBDI

        public TranslationBDI()
    • Method Detail

      • init

        public void init()
      • killed

        public void killed()
        Called when the agent is terminated.