package com.gyee.frame.util.golden.timeseries;

/**
 * @author songwb<songwb@aliyun.com>
 */
public abstract class BasicTsData implements TsData, Comparable<BasicTsData> {

    private final long ts;

    private final short status;

    public BasicTsData(long ts, short status) {
        this.ts = ts;
        this.status = status;
    }

    public long getTs() {
        return ts;
    }

    public short getStatus() {
        return status;
    }

    @Override
    public int compareTo(BasicTsData o) {
        return Long.compare(ts, o.ts);
    }

    @Override
    public String toString() {
        return "BasicTsData{ts='" + ts +
                "', status='" + this.getStatus() +
                "'}";
    }

}

