diff --git a/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/dao/SearchBuilder.java b/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/dao/SearchBuilder.java index 188821dad02..229232144e9 100644 --- a/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/dao/SearchBuilder.java +++ b/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/dao/SearchBuilder.java @@ -911,10 +911,6 @@ public class SearchBuilder implements ISearchBuilder { return myCallingDao; } - public PredicateBuilder getPredicateBuilder() { - return myPredicateBuilder; - } - public class IncludesIterator extends BaseIterator implements Iterator { private final RequestDetails myRequest; diff --git a/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/dao/predicate/PredicateBuilder.java b/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/dao/predicate/PredicateBuilder.java index aa1f39cc5f7..c0da5ee5027 100644 --- a/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/dao/predicate/PredicateBuilder.java +++ b/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/dao/predicate/PredicateBuilder.java @@ -31,7 +31,7 @@ public class PredicateBuilder { myPredicateBuilderResourceId = thePredicateBuilderFactory.newPredicateBuilderResourceId(theSearchBuilder); myPredicateBuilderString = thePredicateBuilderFactory.newPredicateBuilderString(theSearchBuilder); myPredicateBuilderTag = thePredicateBuilderFactory.newPredicateBuilderTag(theSearchBuilder); - myPredicateBuilderToken = thePredicateBuilderFactory.newPredicateBuilderToken(theSearchBuilder); + myPredicateBuilderToken = thePredicateBuilderFactory.newPredicateBuilderToken(theSearchBuilder, this); myPredicateBuilderUri = thePredicateBuilderFactory.newPredicateBuilderUri(theSearchBuilder); } diff --git a/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/dao/predicate/PredicateBuilderFactory.java b/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/dao/predicate/PredicateBuilderFactory.java index 640c0cdf90f..ab2a71fc431 100644 --- a/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/dao/predicate/PredicateBuilderFactory.java +++ b/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/dao/predicate/PredicateBuilderFactory.java @@ -23,7 +23,7 @@ public abstract class PredicateBuilderFactory { @Lookup public abstract PredicateBuilderTag newPredicateBuilderTag(SearchBuilder theSearchBuilder); @Lookup - public abstract PredicateBuilderToken newPredicateBuilderToken(SearchBuilder theSearchBuilder); + public abstract PredicateBuilderToken newPredicateBuilderToken(SearchBuilder theSearchBuilder, PredicateBuilder thePredicateBuilder); @Lookup public abstract PredicateBuilderUri newPredicateBuilderUri(SearchBuilder theSearchBuilder); } diff --git a/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/dao/predicate/PredicateBuilderToken.java b/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/dao/predicate/PredicateBuilderToken.java index d51b341e12c..115cccf6129 100644 --- a/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/dao/predicate/PredicateBuilderToken.java +++ b/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/dao/predicate/PredicateBuilderToken.java @@ -38,9 +38,9 @@ class PredicateBuilderToken extends BasePredicateBuilder { private ISearchParamRegistry mySearchParamRegistry; private final PredicateBuilder myPredicateBuilder; - PredicateBuilderToken(SearchBuilder theSearchBuilder) { + PredicateBuilderToken(SearchBuilder theSearchBuilder, PredicateBuilder thePredicateBuilder) { super(theSearchBuilder); - myPredicateBuilder = theSearchBuilder.getPredicateBuilder(); + myPredicateBuilder = thePredicateBuilder; } Predicate addPredicateToken(String theResourceName,