Skip to content

Commit 4c28266

Browse files
authored
Fix @transactional docs regarding method visibility
Closes gh-27001
1 parent b3dcb64 commit 4c28266

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

src/docs/asciidoc/data-access.adoc

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1314,19 +1314,19 @@ Consider the following class definition:
13141314
@Transactional
13151315
public class DefaultFooService implements FooService {
13161316
1317-
Foo getFoo(String fooName) {
1317+
public Foo getFoo(String fooName) {
13181318
// ...
13191319
}
13201320
1321-
Foo getFoo(String fooName, String barName) {
1321+
public Foo getFoo(String fooName, String barName) {
13221322
// ...
13231323
}
13241324
1325-
void insertFoo(Foo foo) {
1325+
public void insertFoo(Foo foo) {
13261326
// ...
13271327
}
13281328
1329-
void updateFoo(Foo foo) {
1329+
public void updateFoo(Foo foo) {
13301330
// ...
13311331
}
13321332
}
@@ -1356,7 +1356,7 @@ Consider the following class definition:
13561356
}
13571357
----
13581358

1359-
Used at the class level as above, the annotation indicates a default for all methods
1359+
Used at the class level as above, the annotation indicates a default for all public methods
13601360
of the declaring class (as well as its subclasses). Alternatively, each method can
13611361
get annotated individually. Note that a class-level annotation does not apply to
13621362
ancestor classes up the class hierarchy; in such a scenario, methods need to be
@@ -1420,19 +1420,19 @@ programming arrangements as the following listing shows:
14201420
@Transactional
14211421
public class DefaultFooService implements FooService {
14221422
1423-
Publisher<Foo> getFoo(String fooName) {
1423+
public Publisher<Foo> getFoo(String fooName) {
14241424
// ...
14251425
}
14261426
1427-
Mono<Foo> getFoo(String fooName, String barName) {
1427+
public Mono<Foo> getFoo(String fooName, String barName) {
14281428
// ...
14291429
}
14301430
1431-
Mono<Void> insertFoo(Foo foo) {
1431+
public Mono<Void> insertFoo(Foo foo) {
14321432
// ...
14331433
}
14341434
1435-
Mono<Void> updateFoo(Foo foo) {
1435+
public Mono<Void> updateFoo(Foo foo) {
14361436
// ...
14371437
}
14381438
}

0 commit comments

Comments
 (0)