protected Evaluatable(string text, DataContext dataContext) { if (text == null) throw ExceptionBuilder.ArgumentNull("text"); _scope = new Scope(); _scope.Parameters.Changed += parameters_Changed; _text = text; DataContext = dataContext; }
/// <summary> /// Creates a new instance of <see cref="Query"/> with the given <see cref="Evaluatable.Text"/>. /// and <see cref="DataContext"/>. /// </summary> /// <param name="text">The text to set <see cref="Evaluatable.Text"/> to.</param> /// <param name="dataContext">The data context to set <see cref="DataContext"/> to.</param> /// <exception cref="ArgumentNullException">Thrown when <paramref name="text"/> is <see langword="null"/>.</exception> public Query(string text, DataContext dataContext) : base(text, dataContext) { }
/// <summary> /// Creates a new instance of <see cref="Query"/> with the given <see cref="DataContext"/> and /// no <see cref="Evaluatable.Text"/>. /// </summary> /// <param name="dataContext">The data context to set <see cref="DataContext"/> to.</param> public Query(DataContext dataContext) : this(String.Empty, dataContext) { }
/// <summary> /// Creates a new instance of <see cref="Evaluatable"/> with the given <see cref="DataContext"/> and /// no <see cref="Text"/>. /// </summary> /// <param name="dataContext">The data context to set <see cref="DataContext"/> to.</param> protected Evaluatable(DataContext dataContext) : this(String.Empty, dataContext) { }