some examples for SpecificationArgumentResolver
This is a simple Spring Boot project which presents Specification Argument Resolver library.
It is an executable jar with embedded H2 db, so just build it with Maven and explore the API. You will find some samples below:
Get all customers:
Delete a customer
curl -X DELETE http://localhost:8080/customers/3
it will perform a soft delete, which you can verify by getting all customers again -- the deleted customer will be still there, but with
deleted = trueflag. As you will see in subsequent points, specification-based query methods will filter it out.
Filter customers (include only not deleted ones) by first name and gender (optionally):
Filter by name (either first or last, case insensitive) with paging: