GetReferences() public method

Provides the possible references for this expression (only available during semantic analysis)
public GetReferences ( INamable instance, BaseFilter expectation, bool last ) : DataDictionary.Interpreter.ReturnValue
instance INamable the instance on which this element should be found.
expectation BaseFilter the expectation on the element found
last bool indicates that this is the last element in a dereference chain
return DataDictionary.Interpreter.ReturnValue
Exemplo n.º 1
0
        /// <summary>
        ///     Provides the possible references for this term (only available during semantic analysis)
        /// </summary>
        /// <param name="instance">the instance on which this element should be found.</param>
        /// <param name="expectation">the expectation on the element found</param>
        /// <param name="last">indicates that this is the last element in a dereference chain</param>
        /// <returns></returns>
        public ReturnValue GetReferences(INamable instance, BaseFilter expectation, bool last)
        {
            ReturnValue retVal = null;

            if (Designator != null)
            {
                retVal = Designator.GetReferences(instance, expectation, last);
            }
            else if (LiteralValue != null)
            {
                retVal = LiteralValue.GetReferences(instance, expectation, last);
            }

            return(retVal);
        }
Exemplo n.º 2
0
        /// <summary>
        ///     Provides the possible references for this dereference expression (only available during semantic analysis)
        /// </summary>
        /// <param name="instance">the instance on which this element should be found.</param>
        /// <param name="expectation">the expectation on the element found</param>
        /// <param name="last">indicates that this is the last element in a dereference chain</param>
        /// <returns></returns>
        public override ReturnValue GetReferences(INamable instance, BaseFilter expectation, bool last)
        {
            ReturnValue retVal = ReturnValue.Empty;

            if (Term != null)
            {
                retVal = Term.GetReferences(instance, expectation, last);
            }
            else
            {
                if (Expression != null)
                {
                    retVal = Expression.GetReferences(instance, expectation, last);
                }
            }

            return(retVal);
        }