Skip to content

Commit 4dffd68

Browse files
committed
DATAJPA-1639 - Polishing.
Improved source layout of the changed section. Fixed one more occurrence of `_Customer` to `Customer_`. Signed-off-by: Jens Schauder <[email protected]>
1 parent 241efcd commit 4dffd68

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/main/asciidoc/jpa.adoc

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -833,7 +833,11 @@ public class CustomerSpecs {
833833
----
834834
====
835835

836-
Admittedly, the amount of boilerplate leaves room for improvement (that may eventually be reduced by Java 8 closures), but the client side becomes much nicer, as you will see later in this section. The `Customer_` type is a metamodel type generated using the JPA Metamodel generator (see the link:$$https://docs.jboss.org/hibernate/jpamodelgen/1.0/reference/en-US/html_single/#whatisit$$[Hibernate implementation's documentation for an example]). So the expression, `_Customer.createdAt`, assumes the `Customer` has a `createdAt` attribute of type `Date`. Besides that, we have expressed some criteria on a business requirement abstraction level and created executable `Specifications`. So a client might use a `Specification` as follows:
836+
Admittedly, the amount of boilerplate leaves room for improvement (that may eventually be reduced by Java 8 closures), but the client side becomes much nicer, as you will see later in this section.
837+
The `Customer_` type is a metamodel type generated using the JPA Metamodel generator (see the link:$$https://docs.jboss.org/hibernate/jpamodelgen/1.0/reference/en-US/html_single/#whatisit$$[Hibernate implementation's documentation for an example]).
838+
So the expression, `Customer_.createdAt`, assumes the `Customer` has a `createdAt` attribute of type `Date`.
839+
Besides that, we have expressed some criteria on a business requirement abstraction level and created executable `Specifications`.
840+
So a client might use a `Specification` as follows:
837841

838842
.Using a simple Specification
839843
====

0 commit comments

Comments
 (0)