2 * Copyright (c) 2010-2023 Contributors to the openHAB project
4 * See the NOTICE file(s) distributed with this work for additional
7 * This program and the accompanying materials are made available under the
8 * terms of the Eclipse Public License 2.0 which is available at
9 * http://www.eclipse.org/legal/epl-2.0
11 * SPDX-License-Identifier: EPL-2.0
13 package org.openhab.binding.robonect.internal.model;
16 * An object holding the timer information of the mower status.
18 * @author Marco Meyer - Initial contribution
23 * an enum defining the possible timer status.
25 public enum TimerMode {
27 * timer is inactive. No timer is set or the mower is not in AUTO mode.
32 * timer is active. The period of the timer is active and the mower is executing it in AUTO mode.
37 * timer is standby. A timer is set, the mower is in AUTO mode but the timer period did not start yet.
47 public int getCode() {
51 public static TimerMode fromCode(int code) {
52 for (TimerMode status : TimerMode.values()) {
53 if (status.code == code) {
61 private TimerMode status;
63 private NextTimer next;
66 * @return - the timer mode. see {@link TimerMode}
68 public TimerMode getStatus() {
73 * @return - information about when the next timer execution will be. See {@link NextTimer}
75 public NextTimer getNext() {
79 public void setStatus(TimerMode status) {
83 public void setNext(NextTimer next) {