Example #1
0
 /// <summary>
 /// Constructs the parser.
 /// </summary>
 /// <param name="errorReporter">The error reporter instance.</param>
 /// <param name="context">The parser context.</param>
 public SoaLanguageParser(ErrorReporter errorReporter, SoaLanguageContext context)
     : base()
 {
     this.errorReporter = errorReporter;
     this.context = context;
 }
Example #2
0
 /// <summary>
 /// Constructs the expression validator.
 /// </summary>
 /// <param name="errorReporter">The error reporter instance.</param>
 /// <param name="context">The parser context.</param>
 public ExpressionValidator(ErrorReporter errorReporter, SoaLanguageContext context)
     : base(errorReporter, context)
 {
 }
Example #3
0
 /// <summary>
 /// Constructs the name validator.
 /// </summary>
 /// <param name="errorReporter">The error reporter instance.</param>
 /// <param name="context">The parser context.</param>
 public NameValidator(ErrorReporter errorReporter, SoaLanguageContext context)
     : base(errorReporter, context)
 {
 }
Example #4
0
 /// <summary>
 /// Constructs the declaration parser.
 /// </summary>
 /// <param name="errorReporter">The error reporter instance.</param>
 /// <param name="context">The parser context.</param>
 public DeclarationParser(ErrorReporter errorReporter, SoaLanguageContext context)
     : base(errorReporter, context)
 {
 }
Example #5
0
 public SourceLocationInfo(DynamicObjectNode node, SoaLanguageContext context)
     : this(node, context.FileName)
 {
 }
Example #6
0
        private static void Parse(SoaModel model, string input, ErrorReporter er)
        {
            SoaLanguageContext lc = new SoaLanguageContext(new FileInfo(input).Name);

            dynamic root = SoaLanguage.Load().Parse(new StreamReader(input), er);

            new DeclarationParser(er, lc).Parse(root);
            new MemberParser(er, lc).Parse(root);
            new ExpressionParser(er, lc).Parse(root);

            new NameValidator(er, lc).Validate(model);
            new BindingValidator(er, lc).Validate(model);
            new ExpressionValidator(er, lc).Validate(model);
        }
Example #7
0
 /// <summary>
 /// Constructs the member parser.
 /// </summary>
 /// <param name="errorReporter">The error reporter instance.</param>
 /// <param name="context">The parser context.</param>
 public MemberParser(ErrorReporter errorReporter, SoaLanguageContext context)
     : base(errorReporter, context)
 {
 }
Example #8
0
 /// <summary>
 /// Constructs the expression parser.
 /// </summary>
 /// <param name="errorReporter">The error reporter instance.</param>
 /// <param name="context">The parser context.</param>
 public ExpressionParser(ErrorReporter errorReporter, SoaLanguageContext context)
     : base(errorReporter, context)
 {
 }