File tree Expand file tree Collapse file tree
src/main/java/com/jarvis/cache/serializer Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1212import java .lang .reflect .ParameterizedType ;
1313import java .lang .reflect .Type ;
1414import java .nio .charset .Charset ;
15+ import java .nio .charset .StandardCharsets ;
1516import java .util .Calendar ;
1617import java .util .Collection ;
1718import java .util .Date ;
@@ -32,7 +33,7 @@ public class FastjsonSerializer implements ISerializer<Object> {
3233 private static final Map <Type , ParameterizedTypeImpl > TYPE_CACHE = new ConcurrentHashMap <>(1024 );
3334
3435 public FastjsonSerializer () {
35- this (Charset . forName ( "UTF8" ) );
36+ this (StandardCharsets . UTF_8 );
3637 }
3738
3839 public FastjsonSerializer (Charset charset ) {
Original file line number Diff line number Diff line change 33import java .lang .reflect .Method ;
44import java .lang .reflect .Type ;
55import java .nio .charset .Charset ;
6+ import java .nio .charset .StandardCharsets ;
67
78/**
89 * Simple String to byte[] (and back) serializer. Converts Strings into bytes
@@ -22,7 +23,7 @@ public class StringSerializer implements ISerializer<String> {
2223 private final Charset charset ;
2324
2425 public StringSerializer () {
25- this (Charset . forName ( "UTF8" ) );
26+ this (StandardCharsets . UTF_8 );
2627 }
2728
2829 public StringSerializer (Charset charset ) {
You can’t perform that action at this time.
0 commit comments