(二)通过JAVA调用SAP接口 (增加一二级参数)

首先建立用来传递数据的实体类SapData,方便直接取出数据进行下一步处理
SapData

/** * Created by gang.xu01@hand-china.com on 2018/12/5 */ public class SapData { // 列数 private int fieldCount; // 列的具体名称 private String[] fieldNames; // 全部数据 private List<Map<String, String>> data; public SapData(int fieldCount, String[] fieldNames, List<Map<String, String>> data) { this.fieldCount = fieldCount; this.fieldNames = fieldNames; this.data = data; } public SapData() { } public int getFieldCount() { return fieldCount; } public void setFieldCount(int fieldCount) { this.fieldCount = fieldCount; } public String[] getFieldNames() { return fieldNames; } public void setFieldNames(String[] fieldNames) { this.fieldNames = fieldNames; } public List<Map<String, String>> getData() { return data; } public void setData(List<Map<String, String>> data) { this.data = data; } @Override public String toString() { return "SapData{" + "fieldCount=" + fieldCount + ", fieldNames=" + Arrays.toString(fieldNames) + ", data=" + data + '}'; } }

内容版权声明:除非注明,否则皆为本站原创文章。

转载注明出处:https://www.heiqu.com/wpwxdz.html