Add more operators to StdOperators

- stricter use of UpdateQuery.set()
- Numbers just use their own type - PBaseNumber
- PEnum just uses its own type
- Expr.factory() to expose factory
This commit is contained in:
Rob Bygrave
2022-11-09 17:47:16 +13:00
parent a4c3949cfc
commit d29ef8934d
13 changed files with 336 additions and 149 deletions
@@ -7,7 +7,7 @@ package io.ebean.typequery;
* @param <T> the number type
*/
@SuppressWarnings("rawtypes")
public abstract class PBaseNumber<R, T extends Comparable> extends PBaseCompareable<R, T, Number> {
public abstract class PBaseNumber<R, T extends Comparable> extends PBaseCompareable<R, T, T> {
/**
* Construct with a property name and root instance.
@@ -6,7 +6,7 @@ package io.ebean.typequery;
* @param <E> the enum specific type
* @param <R> the root query bean type
*/
public final class PEnum<R, E> extends PBaseValueEqual<R, E, Object> {
public final class PEnum<R, E> extends PBaseValueEqual<R, E, E> {
/**
* Construct with a property name and root instance.
@@ -278,7 +278,7 @@ public abstract class TQRootBean<T, R> {
/**
* Specify the properties to be loaded on the 'main' root level entity bean
* also allowing for functions to be used like {@link StdFunctions#max(Query.Property)}.
* also allowing for functions to be used like {@link StdOperators#max(Query.Property)}.
*
* @param properties the list of properties to fetch
*/