Exemple #1
0
        private ClientProblem(PlanningParser.DomainContext domainContext, PlanningParser.ClientProblemContext problemContext)
        {
            _currentCuddIndex = 0;

            DomainName  = domainContext.NAME().GetText();
            ProblemName = problemContext.problemName().GetText();
            AgentId     = problemContext.agentId().GetText();
            Console.WriteLine("Agent id: {0}", AgentId);
            Console.WriteLine("Finishing setting name!");

            Globals.TermInterpreter = new TermInterpreter(problemContext.numericSetting(), domainContext.typeDefine(),
                                                          problemContext.objectDeclaration());
            Console.WriteLine("Finishing genertating term interpreter!");

            GenerateAgentDict();
            Console.WriteLine("Finishing genertating agent!");

            HandlePredicateDefine(domainContext.predicateDefine());
            Console.WriteLine("Finishing handling predicate!");
            //Console.ReadLine();

            HandleEventsDefine(domainContext.eventDefine());
            Console.WriteLine("Finishing handling event define!");
            //Console.ReadLine();

            HandleActionsDefine(domainContext.actionDefine());
            Console.WriteLine("Finishing handling action define!");
            //Console.ReadLine();

            HandleObservationsDefine(domainContext.observationDefine());
            Console.WriteLine("Finishing handling observation define!");
            //Console.ReadLine();

            HandleInitKnowledge(problemContext.initKnowledge());
            Console.WriteLine("Finishing handling init knowledge!");

            HandleInitBelief(problemContext.initBelief());
            Console.WriteLine("Finishing handling init belief!");

            GenerateAgentList();
            Console.WriteLine("Finishing generating agent list!");
        }
Exemple #2
0
 public override void EnterClientProblem(PlanningParser.ClientProblemContext context)
 {
     Problem.Name       = context.problemName().GetText();
     Problem.DomainName = context.domainName().GetText();
     Problem.AgentId    = context.agentId().GetText();
 }