/** * Copyright (C) 2018 Christian Pierre MOMON * * This file is part of (April) Hebdobot. * * Hebdobot is free software: you can redistribute it and/or modify * it under the terms of the GNU Affero General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * * Hebdobot is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Affero General Public License for more details. * * You should have received a copy of the GNU Affero General Public License * along with Hebdobot. If not, see */ package org.april.hebdobot.model.stats; /** * The Class Stat. */ public class IntegerStat { private int value; private int count; /** * Instantiates a new distribution pair. * * @param value * the value */ public IntegerStat(final int value) { this(value, 0); } /** * Instantiates a new distribution pair. * * @param value * the value * @param count * the count */ public IntegerStat(final int value, final int count) { this.value = value; this.count = count; } /** * Decrease count. */ public void dec() { this.count -= 1; } /** * Gets the count. * * @return the count */ public int getCount() { int result; result = this.count; // return result; } /** * Gets the value. * * @return the value */ public int getValue() { int result; result = this.value; // return result; } /** * Increments count. */ public void inc() { this.count += 1; } }