mirror of
https://github.com/alibaba/druid.git
synced 2023-03-04 19:17:16 +00:00
#2115 add flag to pointed out whether the variable has word 'session' above
This commit is contained in:
@@ -28,6 +28,8 @@ public class SQLVariantRefExpr extends SQLExprImpl {
|
||||
|
||||
private boolean global = false;
|
||||
|
||||
private boolean hasSessionBefore = false;
|
||||
|
||||
private int index = -1;
|
||||
|
||||
public SQLVariantRefExpr(String name){
|
||||
@@ -39,6 +41,12 @@ public class SQLVariantRefExpr extends SQLExprImpl {
|
||||
this.global = global;
|
||||
}
|
||||
|
||||
public SQLVariantRefExpr(String name, boolean global,boolean hasSessionBefore){
|
||||
this.name = name;
|
||||
this.global = global;
|
||||
this.hasSessionBefore = hasSessionBefore;
|
||||
}
|
||||
|
||||
public SQLVariantRefExpr(){
|
||||
|
||||
}
|
||||
@@ -63,6 +71,15 @@ public class SQLVariantRefExpr extends SQLExprImpl {
|
||||
buf.append(this.name);
|
||||
}
|
||||
|
||||
|
||||
public boolean isHasSessionBefore() {
|
||||
return hasSessionBefore;
|
||||
}
|
||||
|
||||
public void setHasSessionBefore(boolean hasSessionBefore) {
|
||||
this.hasSessionBefore = hasSessionBefore;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void accept0(SQLASTVisitor visitor) {
|
||||
visitor.visit(this);
|
||||
|
||||
Reference in New Issue
Block a user