]> git.basschouten.com Git - openhab-addons.git/blob
dc8df1d07bfbe199ca1b8affc8091d556f5803d5
[openhab-addons.git] /
1 /**
2  * Copyright (c) 2010-2023 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.ecovacs.internal.api.model;
14
15 import java.util.Date;
16 import java.util.Optional;
17
18 import org.eclipse.jdt.annotation.NonNullByDefault;
19
20 /**
21  * @author Danny Baumann - Initial contribution
22  */
23 @NonNullByDefault
24 public class CleanLogRecord {
25     public final Date timestamp;
26     public final long cleaningDuration;
27     public final int cleanedArea;
28     public final Optional<String> mapImageUrl;
29     public final CleanMode mode;
30
31     public CleanLogRecord(long timestamp, long duration, int area, Optional<String> mapImageUrl, CleanMode mode) {
32         this.timestamp = new Date(timestamp * 1000);
33         this.cleaningDuration = duration;
34         this.cleanedArea = area;
35         this.mapImageUrl = mapImageUrl;
36         this.mode = mode;
37     }
38 }