public class QueryFactory extends Object
Modifier and Type | Class and Description |
---|---|
static class |
QueryFactory.Builder |
Modifier and Type | Method and Description |
---|---|
static QueryFactory.Builder |
builder() |
static <T> Queryable |
clone(Queryable queryable) |
static <T> Queryable |
clone(Queryable queryable,
Class<T> returnType)
Clone
queryable object with a return type if no null |
static <T> Queryable |
clone(Queryable queryable,
RegisterType registerType)
Clone
queryable object with a return type if no null |
static <T> Queryable |
clone(Queryable queryable,
RegisterType registerType,
Class<T> returnType) |
static <T> Queryable |
clone(String queryName,
Queryable queryable,
Object params,
RegisterType registerType,
Class<T> returnType)
Clone
queryable object with a return type if no null |
static <T> Queryable |
of(String name,
Class<T> returnType)
Build a new
Queryable object |
static <T> Queryable |
of(String name,
Class<T> returnType,
Object... args)
Build a new
Queryable object |
static <T> Queryable |
of(String name,
Class<T> returnType,
Object params)
Creates a
Queryable object parameterized starting at first row and retrieve all rows,
isolation default, no timeout and online (no batch). |
static Queryable |
of(String name,
int offset,
int max)
Build a new
Queryable object without parameters |
static Queryable |
of(String name,
Object... params)
Creates a Query object parameterized starting at first row and retrieve all rows, isolation default, no timeout and online (no batch).
|
static Queryable |
of(String name,
Object params)
Creates a
Queryable object parameterized starting at first row and retrieve all rows,
isolation default, no timeout and online (no batch). |
static Queryable |
of(String name,
Object params,
int offset,
int max)
Build a new
Queryable object |
static Queryable |
of(String name,
RegisterType registerType,
Object... args) |
static Queryable |
ofArray(String name,
Object... params)
Creates a
Queryable object parameterized starting at first row and retrieve all rows,
isolation default, no timeout and online (no batch). |
static Queryable |
ofArray(String name,
RegisterType registerType,
Object... params) |
public static Queryable of(String name, Object... params)
name
- query nameparams
- dynamically arguments to create Queryable
.
1o first param it's key name and 2o your value
3o it's key 4o your value and so on.
public static Queryable of(String name, RegisterType registerType, Object... args)
public static Queryable of(String name, Object params)
Queryable
object parameterized starting at first row and retrieve all rows,
isolation default, no timeout and online (no batch).name
- query nameparams
- parameters of querypublic static Queryable ofArray(String name, Object... params)
Queryable
object parameterized starting at first row and retrieve all rows,
isolation default, no timeout and online (no batch).name
- query nameparams
- array of parameterspublic static Queryable ofArray(String name, RegisterType registerType, Object... params)
public static Queryable of(String name, Object params, int offset, int max)
Queryable
objectname
- a name for queryparams
- parameters from queryoffset
- the first rowmax
- row numbersoffset
and max
rows.public static Queryable of(String name, int offset, int max)
Queryable
object without parametersname
- a name for queryoffset
- the first rowmax
- row numbersoffset
and max
rows.public static <T> Queryable of(String name, Class<T> returnType, Object... args)
Queryable
objectT
- type of return typename
- query namereturnType
- return type that overload return type from XMLargs
- dynamically arguments to create Queryable
.
1o first param it's key name and 2o your value
3o it's key 4o your value and so on.
Queryable
object with parameters and unlimited result and specific return typepublic static <T> Queryable of(String name, Class<T> returnType, Object params)
Queryable
object parameterized starting at first row and retrieve all rows,
isolation default, no timeout and online (no batch).T
- class type of overload returnname
- query namereturnType
- return type that overload return type from XMLparams
- parameters of queryQueryable
object with parameters and unlimited resultpublic static <T> Queryable of(String name, Class<T> returnType)
Queryable
objectT
- type of return typename
- query namereturnType
- return type that overload return type from XMLQueryable
object with parameters and unlimited result and specific return typepublic static <T> Queryable clone(Queryable queryable, Class<T> returnType)
queryable
object with a return type if no null
T
- type of return typequeryable
- query namereturnType
- type of return that overload return type from XMLpublic static <T> Queryable clone(Queryable queryable, RegisterType registerType)
queryable
object with a return type if no null
T
- type of return typequeryable
- query nameregisterType
- registry of type datapublic static <T> Queryable clone(Queryable queryable, RegisterType registerType, Class<T> returnType)
public static <T> Queryable clone(String queryName, Queryable queryable, Object params, RegisterType registerType, Class<T> returnType)
queryable
object with a return type if no null
T
- type of return typequeryName
- of new queryqueryable
- query instanceparams
- parameter of new queryregisterType
- registry of type datareturnType
- type of return that overload return type from XMLpublic static QueryFactory.Builder builder()
Copyright © 2012–2020 jkniv, copyleft code. All rights reserved.