|
@@ -0,0 +1,167 @@
|
|
|
+package com.winhc.bigdata.flink.java.entity;
|
|
|
+
|
|
|
+import com.fasterxml.jackson.core.JsonProcessingException;
|
|
|
+import com.fasterxml.jackson.databind.JsonNode;
|
|
|
+import com.fasterxml.jackson.databind.ObjectMapper;
|
|
|
+import lombok.Data;
|
|
|
+import lombok.var;
|
|
|
+
|
|
|
+import java.util.List;
|
|
|
+import java.util.Map;
|
|
|
+
|
|
|
+/**
|
|
|
+ * @author ZhangJi
|
|
|
+ * @since 2021-10-14 10:07
|
|
|
+ */
|
|
|
+@Data
|
|
|
+public class CompanyDataReceive {
|
|
|
+ private String requestId;
|
|
|
+ private String sessionId;
|
|
|
+ private ReceiveMeta meta;
|
|
|
+ private Map<String, List<JsonNode>> data;
|
|
|
+ private JsonNode company;
|
|
|
+
|
|
|
+ public ReceiveMeta getMeta() {
|
|
|
+ return meta;
|
|
|
+ }
|
|
|
+
|
|
|
+ public Map<String, List<JsonNode>> getData() {
|
|
|
+ return data;
|
|
|
+ }
|
|
|
+
|
|
|
+ public void setCompany(JsonNode company) {
|
|
|
+ this.company = company;
|
|
|
+ }
|
|
|
+
|
|
|
+ public JsonNode getCompany() {
|
|
|
+ return company;
|
|
|
+ }
|
|
|
+
|
|
|
+ public static void main(String[] args) throws JsonProcessingException {
|
|
|
+ var s = "{ \n" +
|
|
|
+ " \"meta\":{\n" +
|
|
|
+ " \n" +
|
|
|
+ " },\n" +
|
|
|
+ " \"company\" : {\n" +
|
|
|
+ " \"company_id\" : \"a04963caf9fb971d639caff75a9bf653\", \n" +
|
|
|
+ " \"new_cid\" : null, \n" +
|
|
|
+ " \"base\" : \"js\", \n" +
|
|
|
+ " \"name\" : \"南京绿野仙踪摄影有限公司\", \n" +
|
|
|
+ " \"name_en\" : \"Nanjing Wizard of Oz Photography Co., Ltd.\", \n" +
|
|
|
+ " \"name_alias\" : \"绿野仙踪\", \n" +
|
|
|
+ " \"history_names\" : null, \n" +
|
|
|
+ " \"legal_entity_id\" : \"p1444360499ac9d07c02da55b73d52c48\", \n" +
|
|
|
+ " \"legal_entity_name\" : \"潘振\", \n" +
|
|
|
+ " \"legal_entity_type\" : 1, \n" +
|
|
|
+ " \"reg_number\" : \"320106000094121\", \n" +
|
|
|
+ " \"company_org_type\" : \"有限责任公司(自然人投资或控股)\", \n" +
|
|
|
+ " \"reg_location\" : \"南京市鼓楼区江东北路319号二楼B2075-B2077号\", \n" +
|
|
|
+ " \"estiblish_time\" : \"2007-10-19 00:00:00\", \n" +
|
|
|
+ " \"from_time\" : \"2007-10-19 00:00:00\", \n" +
|
|
|
+ " \"to_time\" : \"2027-10-18 00:00:00\", \n" +
|
|
|
+ " \"business_scope\" : \"摄影服务;玩具、服装、鞋类、文化用品销售。(依法须经批准的项目,经相关部门批准后方可开展经营活动)\", \n" +
|
|
|
+ " \"reg_institute\" : \"南京市鼓楼区市场监督管理局\", \n" +
|
|
|
+ " \"approved_time\" : \"2021-03-22 00:00:00\", \n" +
|
|
|
+ " \"reg_status\" : \"存续(在营、开业、在册)\", \n" +
|
|
|
+ " \"reg_capital\" : \"3万元人民币\", \n" +
|
|
|
+ " \"org_approved_institute\" : null, \n" +
|
|
|
+ " \"parent_company_id\" : null, \n" +
|
|
|
+ " \"company_type\" : 1, \n" +
|
|
|
+ " \"credit_code\" : \"91320106667355766T\", \n" +
|
|
|
+ " \"org_number\" : \"66735576-6\", \n" +
|
|
|
+ " \"score\" : null, \n" +
|
|
|
+ " \"cate_first_code\" : \"27\", \n" +
|
|
|
+ " \"cate_second_code\" : \"24\", \n" +
|
|
|
+ " \"cate_third_code\" : \"493\", \n" +
|
|
|
+ " \"lat\" : \"32.0661519547779\", \n" +
|
|
|
+ " \"lng\" : \"118.745513991916\", \n" +
|
|
|
+ " \"province_code\" : \"32\", \n" +
|
|
|
+ " \"city_code\" : \"01\", \n" +
|
|
|
+ " \"county_code\" : \"06\", \n" +
|
|
|
+ " \"reg_capital_amount\" : 3000000, \n" +
|
|
|
+ " \"reg_capital_currency\" : \"人民币\", \n" +
|
|
|
+ " \"actual_capital_amount\" : 3000000, \n" +
|
|
|
+ " \"actual_capital_currency\" : \"人民币\", \n" +
|
|
|
+ " \"reg_status_std\" : \"存续\", \n" +
|
|
|
+ " \"social_security_staff_num\" : 2, \n" +
|
|
|
+ " \"cancel_date\" : null, \n" +
|
|
|
+ " \"cancel_reason\" : null, \n" +
|
|
|
+ " \"revoke_date\" : null, \n" +
|
|
|
+ " \"revoke_reason\" : null, \n" +
|
|
|
+ " \"emails\" : \"425372106@qq.com\", \n" +
|
|
|
+ " \"phones\" : \"13952093889\", \n" +
|
|
|
+ " \"wechat_public_num\" : null, \n" +
|
|
|
+ " \"logo\" : null, \n" +
|
|
|
+ " \"crawled_time\" : \"2021-09-07 23:24:12\", \n" +
|
|
|
+ " \"create_time\" : \"2021-09-07 23:24:12\", \n" +
|
|
|
+ " \"update_time\" : \"2021-09-07 23:24:12\", \n" +
|
|
|
+ " \"deleted\" : 0\n" +
|
|
|
+ " }, \n" +
|
|
|
+ " \"data\":{\"company_holder\" : [\n" +
|
|
|
+ " {\n" +
|
|
|
+ " \"rowkey\" : null, \n" +
|
|
|
+ " \"company_id\" : \"a04963caf9fb971d639caff75a9bf653\", \n" +
|
|
|
+ " \"company_name\" : \"南京绿野仙踪摄影有限公司\", \n" +
|
|
|
+ " \"holder_name\" : \"潘振\", \n" +
|
|
|
+ " \"holder_id\" : \"p1444360499ac9d07c02da55b73d52c48\", \n" +
|
|
|
+ " \"holder_type\" : 1, \n" +
|
|
|
+ " \"amount\" : 2.1, \n" +
|
|
|
+ " \"capital\" : \"[{\\\"amomon\\\": \\\"2.1万人民币\\\", \\\"paymet\\\": null, \\\"time\\\": \\\"2014-05-30\\\"}]\", \n" +
|
|
|
+ " \"capital_actual\" : \"[]\", \n" +
|
|
|
+ " \"percent\" : 0.7, \n" +
|
|
|
+ " \"create_time\" : \"2021-09-07 23:24:12\", \n" +
|
|
|
+ " \"update_time\" : \"2021-09-07 23:24:12\", \n" +
|
|
|
+ " \"deleted\" : 0\n" +
|
|
|
+ " }, \n" +
|
|
|
+ " {\n" +
|
|
|
+ " \"rowkey\" : null, \n" +
|
|
|
+ " \"company_id\" : \"a04963caf9fb971d639caff75a9bf653\", \n" +
|
|
|
+ " \"company_name\" : \"南京绿野仙踪摄影有限公司\", \n" +
|
|
|
+ " \"holder_name\" : \"夏天\", \n" +
|
|
|
+ " \"holder_id\" : \"p68fedadbd70d991d15bde4e4fcd72d52\", \n" +
|
|
|
+ " \"holder_type\" : 1, \n" +
|
|
|
+ " \"amount\" : 0.9, \n" +
|
|
|
+ " \"capital\" : \"[{\\\"amomon\\\": \\\"0.9万人民币\\\", \\\"paymet\\\": null, \\\"time\\\": \\\"2014-05-30\\\"}]\", \n" +
|
|
|
+ " \"capital_actual\" : \"[]\", \n" +
|
|
|
+ " \"percent\" : 0.3, \n" +
|
|
|
+ " \"create_time\" : \"2021-09-07 23:24:12\", \n" +
|
|
|
+ " \"update_time\" : \"2021-09-07 23:24:12\", \n" +
|
|
|
+ " \"deleted\" : 0\n" +
|
|
|
+ " }\n" +
|
|
|
+ " ], \n" +
|
|
|
+ " \"company_staff\" : [\n" +
|
|
|
+ " {\n" +
|
|
|
+ " \"rowkey\" : null, \n" +
|
|
|
+ " \"company_id\" : \"a04963caf9fb971d639caff75a9bf653\", \n" +
|
|
|
+ " \"company_name\" : \"南京绿野仙踪摄影有限公司\", \n" +
|
|
|
+ " \"hid\" : \"p1444360499ac9d07c02da55b73d52c48\", \n" +
|
|
|
+ " \"staff_name\" : \"潘振\", \n" +
|
|
|
+ " \"staff_type\" : \"执行董事兼总经理\", \n" +
|
|
|
+ " \"create_time\" : \"2021-09-07 23:24:12\", \n" +
|
|
|
+ " \"update_time\" : \"2021-09-07 23:24:12\", \n" +
|
|
|
+ " \"deleted\" : 0\n" +
|
|
|
+ " }, \n" +
|
|
|
+ " {\n" +
|
|
|
+ " \"rowkey\" : null, \n" +
|
|
|
+ " \"company_id\" : \"a04963caf9fb971d639caff75a9bf653\", \n" +
|
|
|
+ " \"company_name\" : \"南京绿野仙踪摄影有限公司\", \n" +
|
|
|
+ " \"hid\" : \"p68fedadbd70d991d15bde4e4fcd72d52\", \n" +
|
|
|
+ " \"staff_name\" : \"夏天\", \n" +
|
|
|
+ " \"staff_type\" : \"监事\", \n" +
|
|
|
+ " \"create_time\" : \"2021-09-07 23:24:12\", \n" +
|
|
|
+ " \"update_time\" : \"2021-09-07 23:24:12\", \n" +
|
|
|
+ " \"deleted\" : 0\n" +
|
|
|
+ " }\n" +
|
|
|
+ " ]},\n" +
|
|
|
+ " \"time\" : \"2021-09-07\", \n" +
|
|
|
+ " \"company_cid\" : \"a04963caf9fb971d639caff75a9bf653\", \n" +
|
|
|
+ " \"yhc_time\" : \"2021-09-08\", \n" +
|
|
|
+ " \"yhc_source\" : 1\n" +
|
|
|
+ "}\n";
|
|
|
+ ObjectMapper objectMapper = new ObjectMapper();
|
|
|
+ CompanyDataReceive cdr = objectMapper.readValue(s, CompanyDataReceive.class);
|
|
|
+
|
|
|
+ System.out.println(cdr);
|
|
|
+
|
|
|
+ }
|
|
|
+}
|