Assignment of QueryBuilder variable is by refrence?

While doing this =>

public void fun1(){
    QueryBuilder qb1 = ...build a query by, say, two must conditions...
    fun2(qb1);
}

public void fun2(QueryBuilder qb1){
    QueryBuilder qb2 = qb1;// why they have same refrence ?
    // if I add another must query in qb2 it is also reflected in qb1, why ?
}

Why such behaviour ? Any way to solve this ?

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.