-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interface
UpdateQuery.UpdateQueryProvider
A provider toUpdateQuery
, this provider converts text intoUpdateQuery
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Modifier and Type Method Description List<Condition>
getConditions()
The list of changes as conditions.String
getEntity()
The entity namestatic UpdateQuery.UpdateQueryProvider
getProvider()
Returns theUpdateQuery.UpdateQueryProvider
instanceOptional<JSONQueryValue>
getValue()
Returns the value to update when the query uses JSON value instead of Conditions.static UpdateQuery
parse(String query)
Obtains an instance ofUpdateQuery
from a text string.
-
-
-
Method Detail
-
getEntity
String getEntity()
The entity name- Returns:
- the entity name
-
getConditions
List<Condition> getConditions()
The list of changes as conditions. Each condition will use the equals operator,Operator.EQUALS
, e.g., name = "any name"- Returns:
- the conditions
-
getValue
Optional<JSONQueryValue> getValue()
Returns the value to update when the query uses JSON value instead of Conditions. In an insert, an operation is not able to use both:getConditions()
andgetValue()
. Therefore, execution will use just one operation type.- Returns:
- a
JSONQueryValue
orOptional.empty()
when it usesgetConditions()
-
parse
static UpdateQuery parse(String query)
Obtains an instance ofUpdateQuery
from a text string.- Parameters:
query
- the query- Returns:
UpdateQuery
instance- Throws:
NullPointerException
- when the query is nullQuerySyntaxException
- if the text cannot be parsedProviderNotFoundException
- when the provider is not found
-
getProvider
static UpdateQuery.UpdateQueryProvider getProvider()
Returns theUpdateQuery.UpdateQueryProvider
instance- Returns:
- the UpdateQueryProvider instance
- Throws:
ProviderNotFoundException
- when the provider is not found
-
-