Class AbstractModel

    • Field Detail

      • objectMapper

        private static com.fasterxml.jackson.databind.ObjectMapper objectMapper
      • DATE_FORMAT

        public static final DateFormat DATE_FORMAT
    • Constructor Detail

      • AbstractModel

        public AbstractModel()
    • Method Detail

      • getMapperInstance

        public static com.fasterxml.jackson.databind.ObjectMapper getMapperInstance()
      • getReaderInstance

        private static <T> com.fasterxml.jackson.databind.ObjectReader getReaderInstance​(Class<T> clazz)
      • fromJSON

        public static <T> T fromJSON​(com.fasterxml.jackson.core.type.TypeReference<T> type,
                                     String json)
                              throws IOException
        Throws:
        IOException
      • toJson

        public String toJson()
                      throws com.fasterxml.jackson.core.JsonProcessingException
        Throws:
        com.fasterxml.jackson.core.JsonProcessingException
      • toJson

        public String toJson​(Object object)
                      throws com.fasterxml.jackson.core.JsonProcessingException
        Throws:
        com.fasterxml.jackson.core.JsonProcessingException
      • getNowFormatted

        private static String getNowFormatted()
      • getDateNowFormatted

        public static Date getDateNowFormatted()