]> git.basschouten.com Git - openhab-addons.git/blob
c7b0de70438b5604419bff4f50680b2a176c0b05
[openhab-addons.git] /
1 /**
2  * Copyright (c) 2010-2021 Contributors to the openHAB project
3  *
4  * See the NOTICE file(s) distributed with this work for additional
5  * information.
6  *
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
10  *
11  * SPDX-License-Identifier: EPL-2.0
12  */
13 package org.openhab.binding.network.internal;
14
15 /**
16  * The {@link SpeedTestConfiguration} is the class used to match the
17  * thing configuration.
18  *
19  * @author GaĆ«l L'hopital - Initial contribution
20  */
21 public class SpeedTestConfiguration {
22     public Integer refreshInterval = 20;
23     public Integer initialDelay = 5;
24     public Integer uploadSize = 1000000;
25     public Integer maxTimeout = 3;
26     private String url;
27     private String fileName;
28
29     public String getUploadURL() {
30         return url + (url.endsWith("/") ? "" : "/");
31     }
32
33     public String getDownloadURL() {
34         return getUploadURL() + fileName;
35     }
36 }