Example #1
0
        public ITerminalWrapper CreateWrapper(IStaticReturnType terminal)
        {
            if (terminal == null)
            {
                return(null);
            }

            return((ITerminalWrapper)CreateWrapperFor((dynamic)terminal));
        }
        public Type GetTypeByIdentifier(Identifier key)
        {
            if (!ContainsIdentifier(key))
            {
                return(typeof(object));
            }

            IStaticReturnType terminal = _identifierLookupTable[key] as IStaticReturnType;

            return(terminal != null?terminal.GetReturnType() : typeof(object));
        }
 public QuestionUnit(Identifier identifier, IStaticReturnType dataType, string displayText)
     : base(identifier, dataType, displayText)
 {
 }
 public QuestionUnit(Identifier identifier, IStaticReturnType dataType, string displayText, SourceLocation sourceLocation)
     : base(identifier, dataType, displayText, sourceLocation)
 {
 }
Example #5
0
 public StatementUnit(Identifier identifier, Expression expression, string unitText, IStaticReturnType dataType, SourceLocation sourceLocation)
     : base(identifier, dataType, unitText, sourceLocation)
 {
     Expression = expression;
 }
 Type DetermineType(IStaticReturnType type)
 {
     return type.GetReturnType();
 }
Example #7
0
 public NumberWrapper(IStaticReturnType value)
 {
     throw new Exception("Resolution of this IResolvableTerminalType not implemented: " + value);
 }
Example #8
0
 public StatementUnit(Identifier identifier, Expression expression, string unitText, IStaticReturnType dataType, SourceLocation sourceLocation)
     : base(identifier, dataType, unitText, sourceLocation)
 {
     Expression = expression;
 }
 private ITerminalWrapper CreateWrapperFor(IStaticReturnType terminal)
 {
     throw new QLError("Unrecognised type: " + terminal.GetType());
 }
        public ITerminalWrapper CreateWrapper(IStaticReturnType terminal)
        {
            if (terminal == null) return null;

            return (ITerminalWrapper)CreateWrapperFor((dynamic)terminal);
        }
Example #11
0
 public QuestionUnit(Identifier identifier, IStaticReturnType dataType, string displayText)
     : base(identifier, dataType, displayText)
 {
 }
Example #12
0
 public QuestionUnit(Identifier identifier, IStaticReturnType dataType, string displayText, SourceLocation sourceLocation)
     : base(identifier, dataType, displayText, sourceLocation)
 {
 }
Example #13
0
 private ITerminalWrapper CreateWrapperFor(IStaticReturnType terminal)
 {
     throw new QLError("Unrecognised type: " + terminal.GetType());
 }
 public NumberWrapper(IStaticReturnType value)
 {
     throw new Exception("Resolution of this IResolvableTerminalType not implemented: " + value);
 }
 protected UnitBase(Identifier identifier, IStaticReturnType dataType, string displayText, SourceLocation sourceLocation)
     : this(identifier, dataType, displayText)
 {
     SourceLocation = sourceLocation;
 }
 protected UnitBase(Identifier identifier, IStaticReturnType dataType, string displayText)
 {
     Identifier = identifier;
     DataType   = dataType;
     Text       = UnwrapQuotes(displayText);
 }