Beispiel #1
0
        /// <summary>
        /// Handles the AST node visit.
        /// </summary>
        /// <param name="astNode">AST node.</param>
        public override void Visit(AndDaGdAstNode astNode)
        {
            AndDurativeExpression andExpression = new AndDurativeExpression();

            astNode.Arguments.ForEach(arg => andExpression.Arguments.Add(MasterExporter.ToDurativeExpression(arg)));
            ExpressionData = andExpression;
        }
 /// <summary>
 /// Handles the AST node visit.
 /// </summary>
 /// <param name="astNode">AST node.</param>
 public override void Visit(WhenDaEffectAstNode astNode)
 {
     EffectsData.Add(new WhenDurativeEffect(MasterExporter.ToDurativeExpression(astNode.Condition), (TimedEffect)MasterExporter.ToDurativeEffects(astNode.Effect)[0]));
 }
Beispiel #3
0
 /// <summary>
 /// Handles the AST node visit.
 /// </summary>
 /// <param name="astNode">AST node.</param>
 public override void Visit(PreferenceDaGdAstNode astNode)
 {
     ExpressionData = new PreferencedTimedExpression(astNode.Name, (TimedExpression)MasterExporter.ToDurativeExpression(astNode.Argument));
 }
Beispiel #4
0
 /// <summary>
 /// Handles the AST node visit.
 /// </summary>
 /// <param name="astNode">AST node.</param>
 public override void Visit(ForallDaGdAstNode astNode)
 {
     ExpressionData = new ForallDurativeExpression(MasterExporter.ToParameters(astNode.Parameters), MasterExporter.ToDurativeExpression(astNode.Expression));
 }