initial commit: lottery 项目集(三工程统一管理)

- apps/lotteryServer, lotteryCapture, lotteryOpen 三个业务工程
- 忽略 archive/, tools/, infra/data/ 大目录与敏感配置文件
- 移除 lotteryServer 原嵌套 git,并入顶层统一管理
This commit is contained in:
feng0207
2026-09-17 19:03:32 +08:00
commit 3fc4dcc777
2251 changed files with 459578 additions and 0 deletions
@@ -0,0 +1,32 @@
package javautils.json;
import com.fasterxml.jackson.core.JsonProcessingException;
import com.fasterxml.jackson.databind.ObjectMapper;
public class JacksonUtil {
public static String toJSON(Object o) {
try {
ObjectMapper objectMapper = new ObjectMapper();
return objectMapper.writeValueAsString(o);
} catch (JsonProcessingException e) {
e.printStackTrace();
}
return null;
}
public static <T> T toObject(String json, Class<T> clazz) {
try {
ObjectMapper objectMapper = new ObjectMapper();
return objectMapper.readValue(json, clazz);
} catch (Exception e) {
e.printStackTrace();
}
return null;
}
public static void main(String[] args) {
}
}