Esempio n. 1
0
 private FilteredJoin buildFilteredJoin(MatchResult result, Join join, IRightJoinItem joinItem, string alias)
 {
     MatchResult innerResult = result.Matches[SqlGrammar.FilteredJoinType.InnerJoin];
     if (innerResult.IsMatch)
     {
         return join.InnerJoin(joinItem, alias);
     }
     MatchResult leftResult = result.Matches[SqlGrammar.FilteredJoinType.LeftOuterJoin];
     if (leftResult.IsMatch)
     {
         return join.LeftOuterJoin(joinItem, alias);
     }
     MatchResult rightResult = result.Matches[SqlGrammar.FilteredJoinType.RightOuterJoin];
     if (rightResult.IsMatch)
     {
         return join.RightOuterJoin(joinItem, alias);
     }
     MatchResult fullResult = result.Matches[SqlGrammar.FilteredJoinType.FullOuterJoin];
     if (fullResult.IsMatch)
     {
         return join.FullOuterJoin(joinItem, alias);
     }
     throw new InvalidOperationException();
 }