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

io.deepsense.neptune.clientlibrary.models.ChartSeries Maven / Gradle / Ivy

There is a newer version: 1.6.1
Show newest version
/**
 * Copyright (c) 2016, CodiLime Inc.
 */

package io.deepsense.neptune.clientlibrary.models;

import com.google.common.base.Preconditions;

/**
 * Representing series of the chart.
 */
public class ChartSeries {

    private final String name;

    private final Channel channel;

    private final ChartSeriesType type;

    public ChartSeries(String name, Channel channel) {
        this(name, channel, ChartSeriesType.LINE);
    }

    public ChartSeries(String name, Channel channel, ChartSeriesType type) {
        this.name = Preconditions.checkNotNull(name);
        this.channel = Preconditions.checkNotNull(channel);
        this.type = Preconditions.checkNotNull(type);
    }

    /**
     *
     * @return The name of this chart series.
     */
    public String getName() {
        return name;
    }

    /**
     *
     * @return Channel which values will be displayed on this series.
     */
    public Channel getChannel() {
        return channel;
    }

    /**
     *
     * @return Type of series {@link ChartSeriesType}.
     */
    public ChartSeriesType getType() {
        return type;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy