Class SubqueryConjunctionTest
java.lang.Object
ubic.gemma.persistence.util.SubqueryConjunctionTest
A
Subquery may carry several conjoined filters, so that they bind to the SAME element of a
to-many relation.
The distinction this exists for: two separate subqueries ask "has a characteristic valued X" AND "has a characteristic categorised Y", which is satisfied by a dataset where those are two different characteristics. One subquery over two filters asks for a single characteristic that is both — the only form that can express "this gene URI, as a genotype".
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidvoidBoth conditions land in ONE subquery, joined by `and`, against one alias.voidRendering and binding derive parameter names independently; if they drift, the query builds and then dies at bind time.voidgetFilter() is only meaningful for a single filter; a conjunction must be read via getFilters().voidA single-filter subquery must render and bind exactly as it did before conjunctions existed.void
-
Constructor Details
-
SubqueryConjunctionTest
public SubqueryConjunctionTest()
-
-
Method Details
-
bothConditionsAreRenderedInsideASingleSubquery
@Test public void bothConditionsAreRenderedInsideASingleSubquery()Both conditions land in ONE subquery, joined by `and`, against one alias. -
everyRenderedParameterIsBound
@Test public void everyRenderedParameterIsBound()Rendering and binding derive parameter names independently; if they drift, the query builds and then dies at bind time. Conjunct 0 must keep the name it had when a subquery held one filter. -
singleFilterSubqueryIsUnchanged
@Test public void singleFilterSubqueryIsUnchanged()A single-filter subquery must render and bind exactly as it did before conjunctions existed. -
toStringRendersTheConjunction
@Test public void toStringRendersTheConjunction() -
getFilterRefusesToSpeakForAConjunction
@Test public void getFilterRefusesToSpeakForAConjunction()getFilter() is only meaningful for a single filter; a conjunction must be read via getFilters(). -
aSubqueryMustCarryAtLeastOneFilter
@Test public void aSubqueryMustCarryAtLeastOneFilter()
-