ReportSuiteEvent.java 1.14 KB
/*
 * Decompiled with CFR 0_118.
 * 
 * Could not load the following classes:
 *  org.apache.sling.commons.json.JSONArray
 *  org.apache.sling.commons.json.JSONException
 *  org.apache.sling.commons.json.JSONObject
 */
package com.day.cq.analytics.sitecatalyst.rsmerger.impl;

import com.day.cq.analytics.sitecatalyst.rsmerger.AbstractReportSuite;
import com.day.cq.analytics.sitecatalyst.rsmerger.impl.Event;
import java.util.ArrayList;
import java.util.Collection;
import org.apache.sling.commons.json.JSONArray;
import org.apache.sling.commons.json.JSONException;
import org.apache.sling.commons.json.JSONObject;

@Deprecated
public class ReportSuiteEvent
extends AbstractReportSuite {
    Collection<Event> events;

    public ReportSuiteEvent(JSONObject jsonObj) throws JSONException {
        super(jsonObj);
        JSONArray jsonArray = jsonObj.getJSONArray("events");
        this.events = new ArrayList<Event>(jsonArray.length());
        for (int i = 0; i < jsonArray.length(); ++i) {
            this.events.add(new Event(jsonArray.getJSONObject(i)));
        }
    }

    public Collection<Event> getVariables() {
        return this.events;
    }
}