Refactor constants and add private constructor in JsonConf.
Changed API_EMAIL and API_KEY to static final for proper constant usage. Added a private constructor in JsonConf to prevent instantiation, ensuring adherence to utility class design principles.
This commit is contained in:
@@ -12,6 +12,9 @@ import com.fasterxml.jackson.datatype.jsr310.JavaTimeModule;
|
||||
*/
|
||||
class JsonConf {
|
||||
|
||||
private JsonConf() {
|
||||
}
|
||||
|
||||
static ObjectMapper initObjectMapper() {
|
||||
ObjectMapper mapper = new ObjectMapper();
|
||||
mapper.registerModule(new JavaTimeModule());
|
||||
|
||||
Reference in New Issue
Block a user