Class CADBComparisons
java.lang.Object
com.io7m.cardant.database.postgres.internal.CADBComparisons
Functions to perform comparisons over fields/columns.
-
Method Summary
Modifier and TypeMethodDescriptionstatic <T> org.jooq.ConditioncreateExactMatchQuery(CAComparisonExactType<T> query, org.jooq.TableField<org.jooq.Record, T> fieldExact) Create an exact match expression.static <T> org.jooq.ConditioncreateFuzzyMatchQuery(CAComparisonFuzzyType<T> query, org.jooq.Field<T> fieldExact, String fieldSearch) Create a fuzzy match expression.static org.jooq.ConditioncreateSetMatchQueryLong(CAComparisonSetType<Long> query, org.jooq.TableField<org.jooq.Record, Long[]> field) Create a set match expression.static org.jooq.ConditioncreateSetMatchQueryString(CAComparisonSetType<String> query, org.jooq.TableField<org.jooq.Record, String[]> field) Create a set match expression.
-
Method Details
-
createFuzzyMatchQuery
public static <T> org.jooq.Condition createFuzzyMatchQuery(CAComparisonFuzzyType<T> query, org.jooq.Field<T> fieldExact, String fieldSearch) Create a fuzzy match expression.- Type Parameters:
T- The type of compared values- Parameters:
query- The queryfieldExact- The "exact" fieldfieldSearch- The search field- Returns:
- A fuzzy match condition
-
createExactMatchQuery
public static <T> org.jooq.Condition createExactMatchQuery(CAComparisonExactType<T> query, org.jooq.TableField<org.jooq.Record, T> fieldExact) Create an exact match expression.- Type Parameters:
T- The type of compared values- Parameters:
query- The queryfieldExact- The "exact" field- Returns:
- An exact match condition
-
createSetMatchQueryString
public static org.jooq.Condition createSetMatchQueryString(CAComparisonSetType<String> query, org.jooq.TableField<org.jooq.Record, String[]> field) Create a set match expression.- Parameters:
query- The queryfield- The array-typed field- Returns:
- An exact match condition
-
createSetMatchQueryLong
public static org.jooq.Condition createSetMatchQueryLong(CAComparisonSetType<Long> query, org.jooq.TableField<org.jooq.Record, Long[]> field) Create a set match expression.- Parameters:
query- The queryfield- The array-typed field- Returns:
- An exact match condition
-