All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.aliyun.openservices.log.common.ExportContentColumnStorageDetail Maven / Gradle / Ivy

There is a newer version: 0.6.115
Show newest version
package com.aliyun.openservices.log.common;

import com.alibaba.fastjson.JSONArray;
import com.alibaba.fastjson.JSONObject;

import java.util.ArrayList;

public class ExportContentColumnStorageDetail extends ExportContentDetail {

    private ArrayList columns;

    public ArrayList getColumns() {
        return columns;
    }

    public void setColumns(ArrayList columns) {
        this.columns = columns;
    }

    public ExportContentColumnStorageDetail() {}

    public ExportContentColumnStorageDetail(ArrayList columns) {
        this.columns = columns;
    }

    @Override
    public void deserialize(JSONObject value) {
        JSONArray columnsArray = value.getJSONArray("columns");
        columns = new ArrayList();
        if (columnsArray != null) {
            for (int i=0; i < columnsArray.size(); i++) {
                JSONObject obj = columnsArray.getJSONObject(i);
                if (obj == null) {
                    continue;
                }
                columns.add(new ExportContentStorageColumn(
                        obj.getString("name"),
                        obj.getString("type")
                ));
            }
        }
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy