// Copyright (c) 2020 UWB & LESP.
// The UWB & LESP license this file to you under the MIT license.

package cz.senslog.connector.fetch.senslog.v1;

import cz.senslog.connector.model.config.HostConfig;
import cz.senslog.connector.model.config.PropertyConfig;

import java.util.TimeZone;

public class SenslogSessionProxyConfig {

    private final HostConfig lastObservationHost;
    private final TimeZone timeZone;

    public SenslogSessionProxyConfig(PropertyConfig config) {
        this.lastObservationHost = new HostConfig(config.getPropertyConfig("lastObservationHost"));
        this.timeZone = TimeZone.getTimeZone(config.getStringProperty("timeZone"));
    }

    public HostConfig getLastObservationHost() {
        return lastObservationHost;
    }

    public TimeZone getTimeZone() {
        return timeZone;
    }
}
