Skip to content

Commit 1f6564d

Browse files
committed
improve preamble of Generator.adoc
1 parent c6c8d2c commit 1f6564d

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

documentation/src/main/asciidoc/introduction/Generator.adoc

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -130,9 +130,14 @@ The Metamodel Generator is not currently able to generate finder methods and que
130130

131131
We're going to meet three different kinds of generated method:
132132

133-
- a _named query method_ has its signature and implementation generated directly from a `@NamedQuery` annotation,
134-
- a _query method_ has a signature that's explicitly declared, and a generated implementation which executes a HQL or SQL query specified via a `@HQL` or `@SQL` annotation, and
135-
- a _finder method_ annotated `@Find` has a signature that's explicitly declared, and a generated implementation inferred from the parameter list.
133+
- a _<<generated-named-queries,named query method>>_ has its signature and implementation generated directly from a `@NamedQuery` annotation,
134+
- a _<<generated-query-methods,query method>>_ has a signature that's explicitly declared, and a generated implementation which executes a HQL or SQL query specified via a `@HQL` or `@SQL` annotation, and
135+
- a _<<generated-finder-methods,finder method>>_ annotated `@Find` has a signature that's explicitly declared, and a generated implementation inferred from the parameter list.
136+
137+
We're also going to see two ways that these methods can be called:
138+
139+
- as static methods of a generated abstract class, or
140+
- as <<static-or-instance,instance methods of an interface>> with a generated implementation which may even be <<cdi-bean-injection,injected>>.
136141

137142
To whet our appetites, let's see how this works for a `@NamedQuery`.
138143

@@ -355,6 +360,7 @@ interface Queries {
355360

356361
What if we would like to inject a `Queries` object instead of calling its constructor directly?
357362

363+
[[cdi-bean-injection]]
358364
[%unbreakable]
359365
[TIP]
360366
====

0 commit comments

Comments
 (0)