]> git.basschouten.com Git - openhab-addons.git/blob
1dda3711c04adf66b82144913a69abb0bb5b9100
[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.yamahamusiccast.internal;
14
15 import org.eclipse.jdt.annotation.NonNullByDefault;
16 import org.openhab.core.thing.binding.BaseDynamicStateDescriptionProvider;
17 import org.openhab.core.thing.i18n.ChannelTypeI18nLocalizationService;
18 import org.openhab.core.thing.type.DynamicStateDescriptionProvider;
19 import org.osgi.service.component.annotations.Component;
20 import org.osgi.service.component.annotations.Reference;
21
22 /**
23  * The {@link YamahaMusiccastStateDescriptionProvider} is responsible for handling the state options of a channel.
24  *
25  * @author Lennert Coopman - Initial contribution
26  */
27 @Component(service = { DynamicStateDescriptionProvider.class, YamahaMusiccastStateDescriptionProvider.class })
28 @NonNullByDefault
29 public class YamahaMusiccastStateDescriptionProvider extends BaseDynamicStateDescriptionProvider {
30
31     @Reference
32     protected void setChannelTypeI18nLocalizationService(
33             final ChannelTypeI18nLocalizationService channelTypeI18nLocalizationService) {
34         this.channelTypeI18nLocalizationService = channelTypeI18nLocalizationService;
35     }
36
37     protected void unsetChannelTypeI18nLocalizationService(
38             final ChannelTypeI18nLocalizationService channelTypeI18nLocalizationService) {
39         this.channelTypeI18nLocalizationService = null;
40     }
41 }