Skip to content

Commit ffc857e

Browse files
junghoon-vansmp911de
authored andcommitted
Polishing.
Add missing comma in indexes.adoc. Refine generic map definition statements. Closes #2784
1 parent 01c1135 commit ffc857e

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

src/main/antora/modules/ROOT/pages/redis/redis-repositories/indexes.adoc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -56,8 +56,8 @@ public class Person {
5656
5757
// ... other properties omitted
5858
59-
Map<String,String> attributes; <1>
60-
Map<String Person> relatives; <2>
59+
Map<String, String> attributes; <1>
60+
Map<String, Person> relatives; <2>
6161
List<Address> addresses; <3>
6262
}
6363
----

src/main/antora/modules/ROOT/pages/redis/redis-repositories/mapping.adoc

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ addresses.[work].city = "...
7777
CAUTION: Due to the flat representation structure, Map keys need to be simple types, such as ``String`` or ``Number``.
7878

7979
Mapping behavior can be customized by registering the corresponding `Converter` in `RedisCustomConversions`.
80-
Those converters can take care of converting from and to a single `byte[]` as well as `Map<String,byte[]>`.
80+
Those converters can take care of converting from and to a single `byte[]` as well as `Map<String, byte[]>`.
8181
The first one is suitable for (for example) converting a complex type to (for example) a binary JSON representation that still uses the default mappings hash structure.
8282
The second option offers full control over the resulting hash.
8383

@@ -140,15 +140,15 @@ address = { city : "emond's field", country : "andor" }
140140

141141
The following example shows two examples of `Map` converters:
142142

143-
.Sample Map<String,byte[]> Converters
143+
.Sample Map<String, byte[]> Converters
144144
====
145145
[source,java]
146146
----
147147
@WritingConverter
148-
public class AddressToMapConverter implements Converter<Address, Map<String,byte[]>> {
148+
public class AddressToMapConverter implements Converter<Address, Map<String, byte[]>> {
149149
150150
@Override
151-
public Map<String,byte[]> convert(Address source) {
151+
public Map<String, byte[]> convert(Address source) {
152152
return singletonMap("ciudad", source.getCity().getBytes());
153153
}
154154
}
@@ -157,7 +157,7 @@ public class AddressToMapConverter implements Converter<Address, Map<String,byte
157157
public class MapToAddressConverter implements Converter<Map<String, byte[]>, Address> {
158158
159159
@Override
160-
public Address convert(Map<String,byte[]> source) {
160+
public Address convert(Map<String, byte[]> source) {
161161
return new Address(new String(source.get("ciudad")));
162162
}
163163
}

0 commit comments

Comments
 (0)