package de.ivu.elect.business.system.entity;

import static java.util.Arrays.asList;

/**
 *  on 27.01.2017.
 */
public class HibernateStatistikEntry {

  private final String name;

  private final long value;

  public HibernateStatistikEntry(String name, long value) {
    this.name = name;
    this.value = value;
  }

  public String getName() {
    return name;
  }

  public long getValue() {
    return value;
  }

  @Override
  public String toString() {
    return "|" + String.join("|", asList(getName(), Long.toString(getValue()))) + "|";
  }

  public static String toStringHeader() {
    return "||" + String.join("||",
        asList("Name", "Value")) + "||";
  }
}
