2 * Copyright (c) 2010-2022 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.unifi.internal;
15 import org.eclipse.jdt.annotation.NonNullByDefault;
16 import org.openhab.binding.unifi.internal.handler.UniFiClientThingHandler;
19 * The {@link UniFiClientThingConfig} encapsulates all the configuration options for an instance of the
20 * {@link UniFiClientThingHandler}.
22 * @author Matthew Bowman - Initial contribution
25 @SuppressWarnings("unused")
26 public class UniFiClientThingConfig {
28 private String cid = "";
30 private String site = "";
32 private int considerHome = 180;
34 public String getClientID() {
38 private void setCid(final String cid) {
39 // method to avoid ide auto format mark the field as final
43 public String getSite() {
47 private void setSite(final String site) {
48 // method to avoid ide auto format mark the field as final
52 public int getConsiderHome() {
56 public boolean isValid() {
57 return !cid.isBlank();
60 private void setConsiderHome(final int considerHome) {
61 // method to avoid ide auto format mark the field as final
62 this.considerHome = considerHome;
66 public String toString() {
67 return String.format("UniFiClientConfig{cid: '%s', site: '%s', considerHome: %d}", cid, site, considerHome);