GetValue() public method

Provides the value designated by this designator according to the interpretation context
public GetValue ( DataDictionary.Interpreter.InterpretationContext context ) : IValue
context DataDictionary.Interpreter.InterpretationContext
return IValue
示例#1
0
        /// <summary>
        /// Provides the value associated to this Expression
        /// </summary>
        /// <param name="context">The context on which the value must be found</param>
        /// <returns></returns>
        public Values.IValue GetValue(InterpretationContext context)
        {
            Values.IValue retVal = null;

            if (Designator != null)
            {
                retVal = Designator.GetValue(context);
            }
            else if (LiteralValue != null)
            {
                retVal = LiteralValue.GetValue(context);
            }

            return(retVal);
        }
示例#2
0
        /// <summary>
        ///     Provides the value associated to this Expression
        /// </summary>
        /// <param name="context">The context on which the value must be found</param>
        /// <param name="explain"></param>
        /// <returns></returns>
        public IValue GetValue(InterpretationContext context, ExplanationPart explain)
        {
            IValue retVal = null;

            if (Designator != null)
            {
                retVal = Designator.GetValue(context);
            }
            else if (LiteralValue != null)
            {
                retVal = LiteralValue.GetValue(context, explain);
            }

            return(retVal);
        }