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.neeo.internal;
15 import org.eclipse.jdt.annotation.NonNullByDefault;
16 import org.eclipse.jdt.annotation.Nullable;
19 * Configuration used by {@link org.openhab.binding.neeo.internal.handler.NeeoBrainHandler}
21 * @author Tim Roberts - initial contribution
24 public class NeeoBrainConfig {
28 private String ipAddress;
30 /** Whether to enable forward actions */
31 private boolean enableForwardActions;
33 /** The forward actions chain (comma delimited) */
35 private String forwardChain;
37 /** Whether to discover empty rooms or not */
38 private boolean discoverEmptyRooms;
40 /** The check status interval (in seconds) */
41 private int checkStatusInterval;
44 * Gets the ip address.
46 * @return the ip address
49 public String getIpAddress() {
54 * Sets the ip address.
56 * @param ipAddress the new ip address
58 public void setIpAddress(String ipAddress) {
59 this.ipAddress = ipAddress;
63 * Determines if forward actions is enabled
65 * @return true for enabled, false otherwise
67 public boolean isEnableForwardActions() {
68 return enableForwardActions;
72 * Sets whether to enable forward actions
74 * @param enableForwardActions true to enable, false otherwise
76 public void setEnableForwardActions(boolean enableForwardActions) {
77 this.enableForwardActions = enableForwardActions;
81 * Get's the forward chain
83 * @return the forward chain
86 public String getForwardChain() {
91 * Sets the forward change
93 * @param forwardChain the forward chain
95 public void setForwardChain(String forwardChain) {
96 this.forwardChain = forwardChain;
100 * Whether empty rooms should be discovered or not
102 * @return true to discover empty rooms, false otherwise
104 public boolean isDiscoverEmptyRooms() {
105 return discoverEmptyRooms;
109 * Set's whether to discover empty rooms
111 * @param discoverEmptyRooms true to discover, false otherwise
113 public void setDiscoverEmptyRooms(boolean discoverEmptyRooms) {
114 this.discoverEmptyRooms = discoverEmptyRooms;
118 * Gets the interval (in seconds) to check the brain status
120 * @return the check status interval (negative to disable)
122 public int getCheckStatusInterval() {
123 return checkStatusInterval;
127 * Sets the interval (in seconds) to check the brain status
129 * @param checkStatusInterval return the check status interval (negative to disable)
131 public void setCheckStatusInterval(int checkStatusInterval) {
132 this.checkStatusInterval = checkStatusInterval;
136 public String toString() {
137 return "NeeoBrainConfig{" + "ipAddress='" + ipAddress + '\'' + ", enableForwardActions=" + enableForwardActions
138 + ", forwardChain='" + forwardChain + '\'' + ", discoverEmptyRooms=" + discoverEmptyRooms
139 + ", checkStatusInterval=" + checkStatusInterval + '}';