OmniSciDB  a5dc49c757
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
com.mapd.calcite.parser.HeavyDBParser.JoinOperatorChecker Class Reference
+ Inheritance diagram for com.mapd.calcite.parser.HeavyDBParser.JoinOperatorChecker:
+ Collaboration diagram for com.mapd.calcite.parser.HeavyDBParser.JoinOperatorChecker:

Public Member Functions

boolean isEqualityJoinOperator (SqlBasicCall basicCall)
 
Void visit (SqlCall call)
 

Package Functions

boolean containsExpression (SqlNode node)
 

Package Attributes

Set< SqlBasicCall > targetCalls = new HashSet<>()
 

Detailed Description

Definition at line 1845 of file HeavyDBParser.java.

Member Function Documentation

boolean com.mapd.calcite.parser.HeavyDBParser.JoinOperatorChecker.containsExpression ( SqlNode  node)
inlinepackage

Definition at line 1874 of file HeavyDBParser.java.

Referenced by com.mapd.calcite.parser.HeavyDBParser.getPlanner().

1874  {
1875  try {
1876  if (null != node) {
1877  node.accept(this);
1878  for (SqlBasicCall basicCall : targetCalls) {
1879  if (isEqualityJoinOperator(basicCall)) {
1880  throw Util.FoundOne.NULL;
1881  }
1882  }
1883  }
1884  return false;
1885  } catch (Util.FoundOne e) {
1886  return true;
1887  }
1888  }

+ Here is the caller graph for this function:

boolean com.mapd.calcite.parser.HeavyDBParser.JoinOperatorChecker.isEqualityJoinOperator ( SqlBasicCall  basicCall)
inline

Definition at line 1848 of file HeavyDBParser.java.

1848  {
1849  if (null != basicCall) {
1850  if (basicCall.operands.length == 2
1851  && (basicCall.getKind() == SqlKind.EQUALS
1852  || basicCall.getKind() == SqlKind.NOT_EQUALS)
1853  && basicCall.operand(0) instanceof SqlIdentifier
1854  && basicCall.operand(1) instanceof SqlIdentifier) {
1855  return true;
1856  }
1857  }
1858  return false;
1859  }
Void com.mapd.calcite.parser.HeavyDBParser.JoinOperatorChecker.visit ( SqlCall  call)
inline

Definition at line 1862 of file HeavyDBParser.java.

1862  {
1863  if (call instanceof SqlBasicCall) {
1864  targetCalls.add((SqlBasicCall) call);
1865  }
1866  for (SqlNode node : call.getOperandList()) {
1867  if (null != node && !targetCalls.contains(node)) {
1868  node.accept(this);
1869  }
1870  }
1871  return super.visit(call);
1872  }

Member Data Documentation

Set<SqlBasicCall> com.mapd.calcite.parser.HeavyDBParser.JoinOperatorChecker.targetCalls = new HashSet<>()
package

Definition at line 1846 of file HeavyDBParser.java.


The documentation for this class was generated from the following file: