protected override Expression VisitExtensionExpression(ExtensionExpression expression) { if (expression is LuceneQueryExpression) { return VisitLuceneQueryExpression((LuceneQueryExpression)expression); } if (expression is LuceneQueryAnyFieldExpression) { return VisitLuceneQueryAnyFieldExpression((LuceneQueryAnyFieldExpression)expression); } if (expression is LuceneQueryFieldExpression) { return VisitLuceneQueryFieldExpression((LuceneQueryFieldExpression) expression); } if (expression is LuceneQueryPredicateExpression) { return VisitLuceneQueryPredicateExpression((LuceneQueryPredicateExpression) expression); } if (expression is BoostBinaryExpression) { return VisitBoostBinaryExpression((BoostBinaryExpression) expression); } return base.VisitExtensionExpression(expression); }
protected override Expression VisitExtensionExpression(ExtensionExpression expression) #endif { if (expression is SelectIdentifierVariableNameExpression) { var siv = expression as SelectIdentifierVariableNameExpression; var v = _values[siv.Name].ToString(); if (!String.IsNullOrEmpty(siv.IdentifierPrefix) && v.StartsWith(siv.IdentifierPrefix)) { v = v.Substring(siv.IdentifierPrefix.Length); } if (siv.Type.IsInstanceOfType(v)) { return Expression.Constant(v, siv.Type); } var converted = _converter(v, RdfDatatypes.GetLiteralLanguageTag(_values[siv.Name]), siv.Type); return Expression.Constant(converted, siv.Type); } if (expression is SelectVariableNameExpression) { var svn = expression as SelectVariableNameExpression; var v = _values[svn.Name]; if (svn.Type.IsInstanceOfType(v)) { return Expression.Constant(v, svn.Type); } var converted = _converter(v.ToString(), RdfDatatypes.GetLiteralLanguageTag(v), svn.Type); return Expression.Constant(converted, svn.Type); } return expression; }
protected override Expression VisitExtensionExpression(ExtensionExpression expression) { // Nominated expressions need to prevent joins on non-Identifier member expressions // (for the test expression of conditional expressions only) // Otherwise an extra join is created and the GroupBy and Select clauses will not match var old = _preventJoinsInConditionalTest; _preventJoinsInConditionalTest = (NhExpressionType)expression.NodeType == NhExpressionType.Nominator; var expr = base.VisitExtensionExpression(expression); _preventJoinsInConditionalTest = old; return expr; }
protected override Expression VisitExtensionExpression(ExtensionExpression expression) { if (expression is AllowSpecialCharactersExpression) { return VisitAllowSpecialCharactersExpression((AllowSpecialCharactersExpression) expression); } if (expression is LuceneQueryPredicateExpression) { return VisitQueryPredicateExpression((LuceneQueryPredicateExpression) expression); } return base.VisitExtensionExpression(expression); }
protected override Expression VisitExtensionExpression(ExtensionExpression expression) { var aliasExpression = expression as AliasExpression; if (aliasExpression != null) { return VisitExpression(aliasExpression.Expression); } var notNullableExpression = expression as NotNullableExpression; if (notNullableExpression != null) { return expression; } var columnExpression = expression as ColumnExpression ?? expression.TryGetColumnExpression(); if (columnExpression != null && columnExpression.Property.IsNullable) { AddToResult(new IsNullExpression(expression)); return expression; } var isNullExpression = expression as IsNullExpression; if (isNullExpression != null) { return expression; } var inExpression = expression as InExpression; if (inExpression != null) { return expression; } return expression; }
protected override Expression VisitExtensionExpression(ExtensionExpression expression) { return expression is NotNullableExpression ? expression : base.VisitExtensionExpression(expression); }
protected internal override Expression VisitExtensionExpression (ExtensionExpression expression) { ArgumentUtility.CheckNotNull ("expression", expression); return Expression.Parameter (expression.Type, expression.ToString ()); }
protected internal override Expression VisitExtensionExpression(ExtensionExpression expression)
private Expression VisitChildrenWithGivenSemantics (ExtensionExpression expression, SqlExpressionContext childContext) { var visitor = new SqlContextExpressionVisitor (childContext, _stage, _context); return visitor.VisitExtensionExpression (expression); }
protected override Expression VisitExtensionExpression(ExtensionExpression expression) { var notNullableExpression = expression as NotNullableExpression; return notNullableExpression != null ? expression : base.VisitExtensionExpression(expression); }