Uses of Class
com.google.mu.safesql.SafeSql
Packages that use SafeSql
Package
Description
Injection-safe SQL template (requires mug-safesql artifact)
-
Uses of SafeSql in com.google.mu.safesql
Fields in com.google.mu.safesql declared as SafeSqlMethods in com.google.mu.safesql that return SafeSqlModifier and TypeMethodDescriptionstatic SafeSql
SafeSql.nonNegativeLiteral
(int number) Deprecated.static SafeSql
static SafeSql
SafeSql.optionally
(String query, Optional<?> param) Deprecated.UseSafeSql.of("{foo? -> OR foo?}", optionalFoo)
instead ofoptionally("or {foo}", optionalFoo)
because the former allows you to referencefoo?
multiple times in the right hand side snippet.Ifthis
query is empty (likely from a call tooptionally(java.lang.String, java.util.Optional<?>)
orwhen(boolean, java.lang.String, java.lang.Object...)
), returns thefallback
query.Ifthis
query is empty (likely from a call tooptionally(java.lang.String, java.util.Optional<?>)
orwhen(boolean, java.lang.String, java.lang.Object...)
), returns the SafeSql produced from thefallback
template andargs
.Ifthis
query is empty (likely from a call tooptionally(java.lang.String, java.util.Optional<?>)
orwhen(boolean, java.lang.String, java.lang.Object...)
), returns the query produced by thefallback
supplier.SafeSql.when
(boolean condition) Returns this SafeSql ifcondition
is true; otherwise returnsEMPTY
.static SafeSql
An optional query that's only rendered ifcondition
is true; otherwise returnsEMPTY
.Methods in com.google.mu.safesql that return types with arguments of type SafeSqlModifier and TypeMethodDescriptionSafeSql.and()
A collector that joins boolean query snippet usingAND
operator.SafeSql.and()
A collector that joins boolean query snippet usingAND
operator.Returns a collector that joins SafeSql elements usingdelimiter
.Returns a collector that joins SafeSql elements usingdelimiter
.SafeSql.or()
A collector that joins boolean query snippet usingOR
operator.SafeSql.or()
A collector that joins boolean query snippet usingOR
operator.static StringFormat.Template
<SafeSql> Methods in com.google.mu.safesql with parameters of type SafeSqlModifier and TypeMethodDescriptionIfthis
query is empty (likely from a call tooptionally(java.lang.String, java.util.Optional<?>)
orwhen(boolean, java.lang.String, java.lang.Object...)
), returns thefallback
query.Method parameters in com.google.mu.safesql with type arguments of type SafeSqlModifier and TypeMethodDescriptionIfthis
query is empty (likely from a call tooptionally(java.lang.String, java.util.Optional<?>)
orwhen(boolean, java.lang.String, java.lang.Object...)
), returns the query produced by thefallback
supplier.
OFFSET-FETCH
clause, which is parameterizable