2 * Copyright (c) 2010-2021 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 * Object holding information from the status section of the mowers status response.
18 * @author Marco Meyer - Initial contribution
25 private MowerStatus status;
26 private MowerMode mode;
27 private boolean stopped;
30 * @return - the battery level in percent. (0-100)
32 public int getBattery() {
37 * @return - The duration in seconds the mower is already in the current {@link #status}.
39 public int getDuration() {
44 * @return - The hours the mower was in use so far.
46 public int getHours() {
51 * @return - The status the mower is currently in. see {@link MowerStatus} for details.
53 public MowerStatus getStatus() {
58 * @return - true if the mower is currentyl stopped, false otherwise.
60 public boolean isStopped() {
65 * @return - The mode the mower is currently in. See {@link MowerMode} for details.
67 public MowerMode getMode() {
71 public void setBattery(int battery) {
72 this.battery = battery;
75 public void setDuration(int duration) {
76 this.duration = duration;
79 public void setHours(int hours) {
83 public void setStatus(MowerStatus status) {
87 public void setMode(MowerMode mode) {
91 public void setStopped(boolean stopped) {
92 this.stopped = stopped;