/// <summary> /// Create a new FunctionCallToken using the given function name and parameter tokens. /// </summary> /// <param name="name">The name of the function to call.</param> /// <param name="arguments">The arguments for the function.</param> /// <param name="source">The syntactically bound parent of this function</param> public FunctionCallToken(string name, IEnumerable <FunctionParameterToken> arguments, QueryToken source) { ExceptionUtils.CheckArgumentStringNotNullOrEmpty(name, "name"); this.name = name; this.arguments = new ReadOnlyEnumerableForUriParser <FunctionParameterToken>(arguments ?? FunctionParameterToken.EmptyParameterList); this.source = source; }
/// <summary> /// Create a AllToken given the expression, parameter, and parent /// </summary> /// <param name="expression">The associated expression.</param> /// <param name="parameter">The parameter denoting source type.</param> /// <param name="parent">The parent token. Pass null if this property has no parent.</param> public AllToken(QueryToken expression, string parameter, QueryToken parent) : base(expression, parameter, parent) { }
/// <summary> /// Create a new StarToken given the NextToken (if any). /// </summary> /// <param name="nextToken">The NextToken token to access the property on. Pass no if this property has no NextToken.</param> public StarToken(QueryToken nextToken) { this.nextToken = nextToken; }
/// <summary> /// Create a AnyAllQueryToken given the expression, parameter, and parent /// </summary> /// <param name="expression">The associated expression.</param> /// <param name="parameter">The parameter denoting source type.</param> /// <param name="parent">The parent token. Pass null if this property has no parent.</param> protected LambdaToken(QueryToken expression, string parameter, QueryToken parent) { this.expression = expression; this.parameter = parameter; this.parent = parent; }
/// <summary> /// Creates a FunctionParameterToken /// </summary> /// <param name="parameterName">the name of this parameter</param> /// <param name="valueToken">the syntactically parsed value</param> public FunctionParameterToken(string parameterName, QueryToken valueToken) { this.parameterName = parameterName; this.valueToken = valueToken; }