@Override
    public int compareTo(Tyopaiva tyopaiva) {
        if (this.getAlku().get(Calendar.YEAR) == tyopaiva.alku.get(Calendar.YEAR)
                    && this.getAlku().get(Calendar.DAY_OF_MONTH) == tyopaiva.alku.get(Calendar.DAY_OF_MONTH)
                    && this.getAlku().get(Calendar.MONTH) == tyopaiva.alku.get(Calendar.MONTH)) {
            return 0;
        } else if (!this.alku.before(tyopaiva.alku)) {
            return 1;
        } else {
            return -1;
        }
    }