Remove immediate = true from all Components (#8615)

We recommend not to use this on add-ons.

Signed-off-by: Hilbrand Bouwkamp <hilbrand@h72.nl>
This commit is contained in:
Hilbrand Bouwkamp 2020-10-02 05:27:01 +02:00 committed by GitHub
parent f06068a189
commit 003c3af985
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
153 changed files with 155 additions and 157 deletions

View File

@ -38,7 +38,7 @@ import org.slf4j.LoggerFactory;
* @author Mark Theiding - Initial Contribution
*/
@NonNullByDefault
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.adorne")
@Component(service = DiscoveryService.class, configurationPid = "discovery.adorne")
public class AdorneDiscoveryService extends AbstractDiscoveryService implements AdorneHubChangeNotify {
private final Logger logger = LoggerFactory.getLogger(AdorneDiscoveryService.class);

View File

@ -39,7 +39,7 @@ import jcifs.smb.SmbFile;
*
* @author Victor Antonovich - Initial contribution
*/
@Component(service = DiscoveryService.class, immediate = true)
@Component(service = DiscoveryService.class)
public class AirVisualNodeDiscoveryService extends AbstractDiscoveryService {
private final Logger logger = LoggerFactory.getLogger(AirVisualNodeDiscoveryService.class);

View File

@ -40,7 +40,7 @@ import de.kaizencode.tchaikovsky.speaker.Speaker;
*
* @author Dominic Lerbs - Initial contribution
*/
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.allplay")
@Component(service = DiscoveryService.class, configurationPid = "discovery.allplay")
public class AllPlaySpeakerDiscoveryService extends AbstractDiscoveryService implements SpeakerAnnouncedListener {
private final Logger logger = LoggerFactory.getLogger(AllPlaySpeakerDiscoveryService.class);

View File

@ -52,7 +52,7 @@ import org.slf4j.LoggerFactory;
* @author Oliver Libutzki - Initial contribution
*
*/
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.amazondashbutton")
@Component(service = DiscoveryService.class, configurationPid = "discovery.amazondashbutton")
public class AmazonDashButtonDiscoveryService extends AbstractDiscoveryService implements PcapNetworkInterfaceListener {
private static final int DISCOVER_TIMEOUT_SECONDS = 30;

View File

@ -46,7 +46,7 @@ import org.slf4j.LoggerFactory;
* @author Stefan Triller - Use configured location
*/
@NonNullByDefault
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.astro")
@Component(service = DiscoveryService.class, configurationPid = "discovery.astro")
public class AstroDiscoveryService extends AbstractDiscoveryService {
private static final int DISCOVER_TIMEOUT_SECONDS = 2;
private static final int LOCATION_CHANGED_CHECK_INTERVAL = 60;

View File

@ -48,7 +48,7 @@ import org.slf4j.LoggerFactory;
*
* @author Tim Roberts - Initial contribution
*/
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.atlona")
@Component(service = DiscoveryService.class, configurationPid = "discovery.atlona")
public class AtlonaDiscovery extends AbstractDiscoveryService {
private final Logger logger = LoggerFactory.getLogger(AtlonaDiscovery.class);

View File

@ -38,7 +38,7 @@ import org.slf4j.LoggerFactory;
*
*/
@NonNullByDefault
@Component(immediate = true)
@Component
public class AutelisDiscoveryParticipant implements UpnpDiscoveryParticipant {
private final Logger logger = LoggerFactory.getLogger(AutelisDiscoveryParticipant.class);

View File

@ -45,7 +45,7 @@ import org.slf4j.LoggerFactory;
* @author Christoph Weitkamp - Added support for groups
* @author Christoph Weitkamp - Use "discovery.avmfritz:background=false" to disable discovery service
*/
@Component(immediate = true, configurationPid = "discovery.avmfritz")
@Component(configurationPid = "discovery.avmfritz")
@NonNullByDefault
public class AVMFritzUpnpDiscoveryParticipant implements UpnpDiscoveryParticipant {

View File

@ -44,7 +44,7 @@ import org.slf4j.LoggerFactory;
*
* @author Mark Hilbush - Initial contribution
*/
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.bigassfan")
@Component(service = DiscoveryService.class, configurationPid = "discovery.bigassfan")
public class BigAssFanDiscoveryService extends AbstractDiscoveryService {
private final Logger logger = LoggerFactory.getLogger(BigAssFanDiscoveryService.class);

View File

@ -36,7 +36,7 @@ import org.osgi.service.component.annotations.Component;
*
*/
@NonNullByDefault
@Component(immediate = true)
@Component
public class AirthingsDiscoveryParticipant implements BluetoothDiscoveryParticipant {
private static final int AIRTHINGS_COMPANY_ID = 820; // Formerly Corentium AS

View File

@ -37,7 +37,7 @@ import org.osgi.service.component.annotations.Component;
*
*/
@NonNullByDefault
@Component(immediate = true)
@Component
public class AM43DiscoveryParticipant implements BluetoothDiscoveryParticipant {
@Override

View File

@ -35,7 +35,7 @@ import tinyb.BluetoothManager;
* @author Hilbrand Bouwkamp - Moved background scan to actual background method
*
*/
@Component(immediate = true, service = DiscoveryService.class, configurationPid = "discovery.bluetooth.bluez")
@Component(service = DiscoveryService.class, configurationPid = "discovery.bluetooth.bluez")
public class BlueZDiscoveryService extends AbstractDiscoveryService {
private final Logger logger = LoggerFactory.getLogger(BlueZDiscoveryService.class);

View File

@ -37,7 +37,7 @@ import org.osgi.service.component.annotations.Component;
*
*/
@NonNullByDefault
@Component(immediate = true)
@Component
public class BlukiiDiscoveryParticipant implements BluetoothDiscoveryParticipant {
@Override

View File

@ -38,7 +38,7 @@ import org.osgi.service.component.annotations.ReferencePolicy;
* @author Connor Petty - Initial contribution
*/
@NonNullByDefault
@Component(immediate = true, service = { BluetoothDiscoveryParticipant.class })
@Component(service = { BluetoothDiscoveryParticipant.class })
public class RoamingBluetoothDiscoveryParticipant implements BluetoothDiscoveryParticipant {
private final Set<BluetoothAdapter> adapters = new CopyOnWriteArraySet<>();

View File

@ -36,7 +36,7 @@ import org.osgi.service.component.annotations.Component;
*
*/
@NonNullByDefault
@Component(immediate = true)
@Component
public class RuuviTagDiscoveryParticipant implements BluetoothDiscoveryParticipant {
private static final int RUUVITAG_COMPANY_ID = 1177;

View File

@ -54,7 +54,7 @@ import org.slf4j.LoggerFactory;
* @author Connor Petty - Introduced connection based discovery and added roaming support
*/
@NonNullByDefault
@Component(immediate = true, service = DiscoveryService.class, configurationPid = "discovery.bluetooth")
@Component(service = DiscoveryService.class, configurationPid = "discovery.bluetooth")
public class BluetoothDiscoveryService extends AbstractDiscoveryService implements BluetoothDiscoveryListener {
private final Logger logger = LoggerFactory.getLogger(BluetoothDiscoveryService.class);

View File

@ -44,7 +44,7 @@ import org.slf4j.LoggerFactory;
* @author Christian Niessner - Initial contribution
* @author Thomas Traunbauer - Initial contribution
*/
@Component(immediate = true, configurationPid = "discovery.bosesoundtouch")
@Component(configurationPid = "discovery.bosesoundtouch")
public class SoundTouchDiscoveryParticipant implements MDNSDiscoveryParticipant {
private final Logger logger = LoggerFactory.getLogger(SoundTouchDiscoveryParticipant.class);

View File

@ -49,7 +49,7 @@ import org.slf4j.LoggerFactory;
*
* @author Fabio Possieri - Initial contribution
*/
@Component(service = SmartherAccountService.class, immediate = true, configurationPid = "binding.bticinosmarther.accountService")
@Component(service = SmartherAccountService.class, configurationPid = "binding.bticinosmarther.accountService")
@NonNullByDefault
public class SmartherAccountService {

View File

@ -37,7 +37,7 @@ import org.slf4j.LoggerFactory;
* @author Kai Kreuzer - Initial contribution
* @author Daniel Walters - Change discovery protocol to mDNS
*/
@Component(immediate = true)
@Component
@NonNullByDefault
public class ChromecastDiscoveryParticipant implements MDNSDiscoveryParticipant {
private final Logger logger = LoggerFactory.getLogger(ChromecastDiscoveryParticipant.class);

View File

@ -30,7 +30,7 @@ import org.slf4j.LoggerFactory;
* @author Johannes Ott - Initial contribution
*/
@NonNullByDefault
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.coronastats")
@Component(service = DiscoveryService.class, configurationPid = "discovery.coronastats")
public class CoronaStatsDiscoveryService extends AbstractDiscoveryService {
private static final ThingUID WORLD_THING_UID = new ThingUID(THING_TYPE_WORLD, STATS);
private static final int DISCOVER_TIMEOUT_SECONDS = 2;

View File

@ -40,7 +40,7 @@ import org.slf4j.LoggerFactory;
* @author Ralf Duckstein - Initial contribution
* @author Robert Bach - heavy refactorings
*/
@Component(service = DiscoveryService.class, immediate = true)
@Component(service = DiscoveryService.class)
@NonNullByDefault
public class DanfossAirUnitDiscoveryService extends AbstractDiscoveryService {

View File

@ -34,7 +34,7 @@ import org.slf4j.LoggerFactory;
* @author Jan N. Klug - Initial contribution
*/
@NonNullByDefault
@Component(service = { DynamicStateDescriptionProvider.class, StateDescriptionProvider.class }, immediate = true)
@Component(service = { DynamicStateDescriptionProvider.class, StateDescriptionProvider.class })
public class StateDescriptionProvider implements DynamicStateDescriptionProvider {
private final Map<ChannelUID, StateDescription> descriptions = new ConcurrentHashMap<>();

View File

@ -41,7 +41,7 @@ import org.osgi.service.component.annotations.Component;
* @author David Graeff - Initial contribution
*/
@NonNullByDefault
@Component(service = UpnpDiscoveryParticipant.class, immediate = true)
@Component(service = UpnpDiscoveryParticipant.class)
public class BridgeDiscoveryParticipant implements UpnpDiscoveryParticipant {
@Override

View File

@ -37,7 +37,7 @@ import org.slf4j.LoggerFactory;
* @author Jan-Willem Veldhuis - Initial contribution
*
*/
@Component(immediate = true)
@Component
public class DenonMarantzDiscoveryParticipant implements MDNSDiscoveryParticipant {
private Logger logger = LoggerFactory.getLogger(DenonMarantzDiscoveryParticipant.class);

View File

@ -44,7 +44,7 @@ import org.slf4j.LoggerFactory;
* @author Michael Ochel - Initial contribution
* @author Matthias Siegele - Initial contribution
*/
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.digitalstrom")
@Component(service = DiscoveryService.class, configurationPid = "discovery.digitalstrom")
public class BridgeDiscoveryService extends AbstractDiscoveryService {
private final Logger logger = LoggerFactory.getLogger(BridgeDiscoveryService.class);

View File

@ -42,7 +42,7 @@ import org.slf4j.LoggerFactory;
* @author Matthias Siegele - Initial contribution
*
*/
@Component(service = MDNSDiscoveryParticipant.class, immediate = true)
@Component(service = MDNSDiscoveryParticipant.class)
public class BridgeMDNSDiscoveryParticipant implements MDNSDiscoveryParticipant {
private final Logger logger = LoggerFactory.getLogger(BridgeMDNSDiscoveryParticipant.class);

View File

@ -53,7 +53,7 @@ import org.osgi.service.component.annotations.Reference;
* @author Matthias Siegele - Initial contribution
*
*/
@Component(service = ChannelTypeProvider.class, immediate = true)
@Component(service = ChannelTypeProvider.class)
public class DsChannelTypeProvider extends BaseDsI18n implements ChannelTypeProvider {
// channelID building (effect group type + (nothing || SEPERATOR + item type || SEPERATOR + extended item type) e.g.

View File

@ -51,7 +51,7 @@ import org.slf4j.LoggerFactory;
* @author Michael Ochel - initial contributer
* @author Matthias Siegele - initial contributer
*/
@Component(service = ThingTypeProvider.class, immediate = true)
@Component(service = ThingTypeProvider.class)
public class DsDeviceThingTypeProvider extends BaseDsI18n implements ThingTypeProvider {
/**

View File

@ -36,7 +36,7 @@ import org.slf4j.LoggerFactory;
* @author Mike Major - Initial contribution
*
*/
@Component(immediate = true)
@Component
public class DLinkSmartHomeDiscoveryParticipant implements MDNSDiscoveryParticipant {
private static final String SERVICE_TYPE = "_dhnap._tcp.local.";

View File

@ -31,7 +31,7 @@ import org.slf4j.LoggerFactory;
* @author Russell Stephens - Initial Contribution
*
*/
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.dscalarm")
@Component(service = DiscoveryService.class, configurationPid = "discovery.dscalarm")
public class DSCAlarmBridgeDiscovery extends AbstractDiscoveryService {
private final Logger logger = LoggerFactory.getLogger(DSCAlarmBridgeDiscovery.class);

View File

@ -30,7 +30,7 @@ import org.slf4j.LoggerFactory;
* @author Johannes Ott - Initial contribution
*/
@NonNullByDefault
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.dwdpollenflug")
@Component(service = DiscoveryService.class, configurationPid = "discovery.dwdpollenflug")
public class DWDPollenflugDiscoveryService extends AbstractDiscoveryService {
private static final ThingUID BRIDGE_THING_UID = new ThingUID(THING_TYPE_BRIDGE, DWD);
private static final int DISCOVER_TIMEOUT_SECONDS = 2;

View File

@ -41,7 +41,7 @@ import org.slf4j.LoggerFactory;
* @author Guido Dolfen - Initial contribution
*/
@NonNullByDefault
@Component(service = MDNSDiscoveryParticipant.class, immediate = true)
@Component(service = MDNSDiscoveryParticipant.class)
public class Enigma2DiscoveryParticipant implements MDNSDiscoveryParticipant {
private final Logger logger = LoggerFactory.getLogger(Enigma2DiscoveryParticipant.class);

View File

@ -32,7 +32,7 @@ import org.osgi.service.component.annotations.Reference;
*
* @author Joe Inkenbrandt - Initial contribution
*/
@Component(service = ThingHandlerFactory.class, immediate = true, configurationPid = "binding.etherrain")
@Component(service = ThingHandlerFactory.class, configurationPid = "binding.etherrain")
@NonNullByDefault
public class EtherRainHandlerFactory extends BaseThingHandlerFactory {

View File

@ -34,7 +34,7 @@ import org.slf4j.LoggerFactory;
* @author Joe Inkenbrandt - Initial contribution
*/
@NonNullByDefault
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.etherrain")
@Component(service = DiscoveryService.class, configurationPid = "discovery.etherrain")
public class EtherrainDiscoveryService extends AbstractDiscoveryService {
private final Logger logger = LoggerFactory.getLogger(EtherrainDiscoveryService.class);

View File

@ -42,7 +42,7 @@ import org.slf4j.LoggerFactory;
* @author Hilbrand Bouwkamp - Initial contribution
*/
@NonNullByDefault
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.feican")
@Component(service = DiscoveryService.class, configurationPid = "discovery.feican")
public class FeicanDiscoveryService extends AbstractDiscoveryService {
private static final int DISCOVERY_TIMEOUT_SECONDS = 5;

View File

@ -54,7 +54,7 @@ import org.slf4j.LoggerFactory;
* @author Sami Salonen - Initial contribution
*/
@NonNullByDefault
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.fmiweather")
@Component(service = DiscoveryService.class, configurationPid = "discovery.fmiweather")
public class FMIWeatherDiscoveryService extends AbstractDiscoveryService {
private final Logger logger = LoggerFactory.getLogger(FMIWeatherDiscoveryService.class);

View File

@ -33,7 +33,7 @@ import org.osgi.service.component.annotations.Component;
*
* @author Marius Bjoernstad - Initial contribution
*/
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.folding")
@Component(service = DiscoveryService.class, configurationPid = "discovery.folding")
public class FoldingSlotDiscoveryService extends AbstractDiscoveryService {
public FoldingSlotDiscoveryService() {

View File

@ -36,7 +36,7 @@ import org.slf4j.LoggerFactory;
*
* @author Laurent Garnier - Initial contribution
*/
@Component(immediate = true)
@Component
public class FreeboxServerDiscoveryParticipant implements MDNSDiscoveryParticipant {
private final Logger logger = LoggerFactory.getLogger(FreeboxServerDiscoveryParticipant.class);

View File

@ -44,7 +44,7 @@ import org.slf4j.LoggerFactory;
* @author Mihaela Memova - removed the getLabel(RemoteDevice device) method due to its unreachable code lines
* @author Markus Michels - support for Teufel 3sixty discovery
*/
@Component(immediate = true)
@Component
public class FSInternetRadioDiscoveryParticipant implements UpnpDiscoveryParticipant {
private final Logger logger = LoggerFactory.getLogger(FSInternetRadioDiscoveryParticipant.class);

View File

@ -43,7 +43,7 @@ import org.slf4j.LoggerFactory;
*
* @author Mark Hilbush - Initial contribution
*/
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.globalcache")
@Component(service = DiscoveryService.class, configurationPid = "discovery.globalcache")
public class GlobalCacheDiscoveryService extends AbstractDiscoveryService {
private final Logger logger = LoggerFactory.getLogger(GlobalCacheDiscoveryService.class);

View File

@ -40,7 +40,7 @@ import org.osgi.service.component.annotations.Modified;
*/
@NonNullByDefault
@Component(service = { DiscoveryService.class,
TrackerDiscoveryService.class }, immediate = true, configurationPid = "discovery.gpstracker")
TrackerDiscoveryService.class }, configurationPid = "discovery.gpstracker")
public class TrackerDiscoveryService extends AbstractDiscoveryService {
/**
* Discovery timeout

View File

@ -30,7 +30,7 @@ import org.osgi.service.component.annotations.Reference;
* @author Markus Michels - Initial contribution
*/
@NonNullByDefault
@Component(service = GreeTranslationProvider.class, immediate = true, configurationPid = "localization.gree")
@Component(service = GreeTranslationProvider.class, configurationPid = "localization.gree")
public class GreeTranslationProvider {
private final Bundle bundle;

View File

@ -49,7 +49,7 @@ import com.google.gson.JsonSyntaxException;
* @author Markus Michels - Refactoring, adapted to OH 2.5x
*/
@NonNullByDefault
@Component(service = GreeDeviceFinder.class, immediate = true, configurationPid = "devicefinder.gree")
@Component(service = GreeDeviceFinder.class, configurationPid = "devicefinder.gree")
public class GreeDeviceFinder {
private final Logger logger = LoggerFactory.getLogger(GreeDeviceFinder.class);
private static final Gson gson = (new GsonBuilder()).create();

View File

@ -47,7 +47,7 @@ import org.slf4j.LoggerFactory;
*
*/
@NonNullByDefault
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.gree")
@Component(service = DiscoveryService.class, configurationPid = "discovery.gree")
public class GreeDiscoveryService extends AbstractDiscoveryService {
private static final int TIMEOUT_SEC = 10;
private final Logger logger = LoggerFactory.getLogger(GreeDiscoveryService.class);

View File

@ -55,7 +55,7 @@ import org.slf4j.LoggerFactory;
* @author Wouter Born - Add null annotations
*/
@NonNullByDefault
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.harmonyhub")
@Component(service = DiscoveryService.class, configurationPid = "discovery.harmonyhub")
public class HarmonyHubDiscoveryService extends AbstractDiscoveryService {
private final Logger logger = LoggerFactory.getLogger(HarmonyHubDiscoveryService.class);

View File

@ -38,7 +38,7 @@ import org.slf4j.LoggerFactory;
* @author Andrew Fiddian-Green - Initial contribution
*/
@NonNullByDefault
@Component(immediate = true)
@Component
public class HDPowerViewHubDiscoveryParticipant implements MDNSDiscoveryParticipant {
private final Logger logger = LoggerFactory.getLogger(HDPowerViewHubDiscoveryParticipant.class);

View File

@ -39,7 +39,7 @@ import jcifs.netbios.NbtAddress;
* @author Andy Lintner - Initial contribution
*/
@NonNullByDefault
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.hdpowerview")
@Component(service = DiscoveryService.class, configurationPid = "discovery.hdpowerview")
public class HDPowerViewHubDiscoveryService extends AbstractDiscoveryService {
private final Logger logger = LoggerFactory.getLogger(HDPowerViewHubDiscoveryService.class);

View File

@ -42,7 +42,7 @@ import org.slf4j.LoggerFactory;
* @author Johannes Einig - Initial contribution
*/
@NonNullByDefault
@Component(service = UpnpDiscoveryParticipant.class, immediate = true, configurationPid = "discovery.heos")
@Component(service = UpnpDiscoveryParticipant.class, configurationPid = "discovery.heos")
public class HeosDiscoveryParticipant implements UpnpDiscoveryParticipant {
private final Logger logger = LoggerFactory.getLogger(HeosDiscoveryParticipant.class);

View File

@ -39,7 +39,7 @@ import org.slf4j.LoggerFactory;
*
* @author Gerhard Riegler - Initial contribution
*/
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.homematic")
@Component(service = DiscoveryService.class, configurationPid = "discovery.homematic")
public class CcuDiscoveryService extends AbstractDiscoveryService {
private final Logger logger = LoggerFactory.getLogger(CcuDiscoveryService.class);

View File

@ -35,7 +35,7 @@ import org.slf4j.LoggerFactory;
*
* @author Gerhard Riegler - Initial contribution
*/
@Component(immediate = true)
@Component
public class HomegearDiscoveryParticipant implements UpnpDiscoveryParticipant {
private final Logger logger = LoggerFactory.getLogger(HomegearDiscoveryParticipant.class);

View File

@ -34,7 +34,7 @@ import org.osgi.service.component.annotations.ReferencePolicy;
*
* @author Michael Reitler - Initial contribution
*/
@Component(service = { HomematicChannelGroupTypeProvider.class, ChannelGroupTypeProvider.class }, immediate = true)
@Component(service = { HomematicChannelGroupTypeProvider.class, ChannelGroupTypeProvider.class })
public class HomematicChannelGroupTypeProviderImpl implements HomematicChannelGroupTypeProvider {
private final Map<ChannelGroupTypeUID, ChannelGroupType> channelGroupTypesByUID = new HashMap<>();
protected List<HomematicThingTypeExcluder> homematicThingTypeExcluders = new CopyOnWriteArrayList<>();

View File

@ -35,7 +35,7 @@ import org.osgi.service.component.annotations.ReferencePolicy;
* @author Gerhard Riegler - Initial contribution
* @author Michael Reitler - Added HomematicThingTypeExcluder
*/
@Component(service = { HomematicChannelTypeProvider.class, ChannelTypeProvider.class }, immediate = true)
@Component(service = { HomematicChannelTypeProvider.class, ChannelTypeProvider.class })
public class HomematicChannelTypeProviderImpl implements HomematicChannelTypeProvider {
private final Map<ChannelTypeUID, ChannelType> channelTypesByUID = new HashMap<>();
protected List<HomematicThingTypeExcluder> homematicThingTypeExcluders = new CopyOnWriteArrayList<>();

View File

@ -35,7 +35,7 @@ import org.osgi.service.component.annotations.ReferencePolicy;
* @author Gerhard Riegler - Initial contribution
* @author Michael Reitler - Added HomematicThingTypeExcluder
*/
@Component(service = { HomematicConfigDescriptionProvider.class, ConfigDescriptionProvider.class }, immediate = true)
@Component(service = { HomematicConfigDescriptionProvider.class, ConfigDescriptionProvider.class })
public class HomematicConfigDescriptionProviderImpl implements HomematicConfigDescriptionProvider {
private Map<URI, ConfigDescription> configDescriptionsByURI = new HashMap<>();
protected List<HomematicThingTypeExcluder> homematicThingTypeExcluders = new CopyOnWriteArrayList<>();

View File

@ -37,7 +37,7 @@ import org.osgi.service.component.annotations.ReferencePolicy;
* @author Gerhard Riegler - Initial contribution
* @author Michael Reitler - Added HomematicThingTypeExcluder
*/
@Component(service = { HomematicThingTypeProvider.class, ThingTypeProvider.class }, immediate = true)
@Component(service = { HomematicThingTypeProvider.class, ThingTypeProvider.class })
public class HomematicThingTypeProviderImpl implements HomematicThingTypeProvider {
private Map<ThingTypeUID, ThingType> thingTypesByUID = new HashMap<>();
protected List<HomematicThingTypeExcluder> homematicThingTypeExcluders = new CopyOnWriteArrayList<>();

View File

@ -67,7 +67,7 @@ import org.slf4j.LoggerFactory;
*
* @author Gerhard Riegler - Initial contribution
*/
@Component(immediate = true)
@Component
public class HomematicTypeGeneratorImpl implements HomematicTypeGenerator {
private final Logger logger = LoggerFactory.getLogger(HomematicTypeGeneratorImpl.class);
private static URI configDescriptionUriChannel;

View File

@ -39,7 +39,7 @@ import org.slf4j.LoggerFactory;
* @author Stewart Cossey - Initial contribution
*/
@NonNullByDefault
@Component(immediate = true)
@Component
public class HPPrinterDiscoveryParticipant implements MDNSDiscoveryParticipant {
private final Logger logger = LoggerFactory.getLogger(HPPrinterDiscoveryParticipant.class);

View File

@ -41,7 +41,7 @@ import org.osgi.service.component.annotations.Component;
* @author Thomas Höfer - Added representation
*/
@NonNullByDefault
@Component(service = UpnpDiscoveryParticipant.class, immediate = true)
@Component(service = UpnpDiscoveryParticipant.class)
public class HueBridgeDiscoveryParticipant implements UpnpDiscoveryParticipant {
@Override

View File

@ -49,7 +49,7 @@ import com.google.gson.reflect.TypeToken;
* @author Andre Fuechsel - make {@link #startScan()} asynchronous
*/
@NonNullByDefault
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.hue")
@Component(service = DiscoveryService.class, configurationPid = "discovery.hue")
public class HueBridgeNupnpDiscovery extends AbstractDiscoveryService {
private static final String MODEL_NAME_PHILIPS_HUE = "<modelName>Philips hue";

View File

@ -34,7 +34,7 @@ import org.osgi.service.component.annotations.Component;
* @author Daniel Walters - Initial contribution
*/
@Component(immediate = true)
@Component
public class HyperionDiscoveryParticipant implements MDNSDiscoveryParticipant {
@Override

View File

@ -36,7 +36,7 @@ import org.slf4j.LoggerFactory;
*/
@NonNullByDefault
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "binding.ipcamera")
@Component(service = DiscoveryService.class, configurationPid = "binding.ipcamera")
public class IpCameraDiscoveryService extends AbstractDiscoveryService {
private final Logger logger = LoggerFactory.getLogger(IpCameraDiscoveryService.class);

View File

@ -35,7 +35,7 @@ import org.osgi.service.component.annotations.Reference;
*
* @author Matthew Skinner - Initial contribution
*/
@Component(service = ThingHandlerFactory.class, immediate = true, configurationPid = "binding.ipcamera")
@Component(service = ThingHandlerFactory.class, configurationPid = "binding.ipcamera")
@NonNullByDefault
public class IpCameraHandlerFactory extends BaseThingHandlerFactory {
private final @Nullable String openhabIpAddress;

View File

@ -35,7 +35,7 @@ import org.slf4j.LoggerFactory;
*
* @author Tobias Bräutigam - Initial contribution
*/
@Component(immediate = true)
@Component
public class IppPrinterDiscoveryParticipant implements MDNSDiscoveryParticipant {
private final Logger logger = LoggerFactory.getLogger(IppPrinterDiscoveryParticipant.class);

View File

@ -34,8 +34,7 @@ import org.osgi.service.component.annotations.Component;
*
* @author Markus Eckhardt - Initial contribution
*/
@Component(service = { ChannelTypeProvider.class, ChannelGroupTypeProvider.class,
KM200ChannelTypeProvider.class }, immediate = true)
@Component(service = { ChannelTypeProvider.class, ChannelGroupTypeProvider.class, KM200ChannelTypeProvider.class })
@NonNullByDefault
public class KM200ChannelTypeProvider implements ChannelTypeProvider, ChannelGroupTypeProvider {
private final List<ChannelType> channelTypes = new CopyOnWriteArrayList<>();

View File

@ -38,7 +38,7 @@ import org.slf4j.LoggerFactory;
* @author Markus Eckhardt - Initial contribution
*/
@NonNullByDefault
@Component(immediate = true, configurationPid = "binding.km200")
@Component(configurationPid = "binding.km200")
public class KM200GatewayDiscoveryParticipant implements MDNSDiscoveryParticipant {
private final Logger logger = LoggerFactory.getLogger(KM200GatewayDiscoveryParticipant.class);

View File

@ -40,7 +40,7 @@ import org.slf4j.LoggerFactory;
* @author Paul Frank - Initial contribution
* @author Christoph Weitkamp - Use "discovery.kodi:background=false" to disable discovery service
*/
@Component(immediate = true, configurationPid = "discovery.kodi")
@Component(configurationPid = "discovery.kodi")
@NonNullByDefault
public class KodiUpnpDiscoveryParticipant implements UpnpDiscoveryParticipant {

View File

@ -41,7 +41,7 @@ import org.slf4j.LoggerFactory;
*
*/
@NonNullByDefault
@Component(service = UpnpDiscoveryParticipant.class, immediate = true)
@Component(service = UpnpDiscoveryParticipant.class)
public class KonnectedUPnPServer implements UpnpDiscoveryParticipant {
private Logger logger = LoggerFactory.getLogger(KonnectedUPnPServer.class);

View File

@ -44,7 +44,7 @@ import com.google.gson.Gson;
@Provider
@Produces(MediaType.APPLICATION_JSON)
@Consumes(MediaType.APPLICATION_JSON)
@Component(immediate = true)
@Component
public class GsonProvider<T> implements MessageBodyReader<T>, MessageBodyWriter<T> {
private final Gson gson;

View File

@ -36,7 +36,7 @@ import org.slf4j.LoggerFactory;
*
* @author Gregory Moyer - Initial contribution
*/
@Component(immediate = true)
@Component
public class LaMetricTimeDiscoveryParticipant implements UpnpDiscoveryParticipant {
private Logger logger = LoggerFactory.getLogger(LaMetricTimeDiscoveryParticipant.class);

View File

@ -54,7 +54,7 @@ import com.thoughtworks.xstream.io.xml.StaxDriver;
* @author Fabian Wolter - Initial Contribution
*/
@NonNullByDefault
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.lcn")
@Component(service = DiscoveryService.class, configurationPid = "discovery.lcn")
public class LcnPchkDiscoveryService extends AbstractDiscoveryService {
private final Logger logger = LoggerFactory.getLogger(LcnPchkDiscoveryService.class);
private static final String HOSTNAME = "hostname";

View File

@ -35,7 +35,7 @@ import com.leapmotion.leap.Listener;
*
*/
@NonNullByDefault
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.leapmotion")
@Component(service = DiscoveryService.class, configurationPid = "discovery.leapmotion")
public class LeapMotionDiscoveryService extends AbstractDiscoveryService {
private @NonNullByDefault({}) Controller leapController;

View File

@ -37,7 +37,7 @@ import org.slf4j.LoggerFactory;
* @author Sebastian Prehn - Initial contribution
*/
@NonNullByDefault
@Component(service = UpnpDiscoveryParticipant.class, immediate = true, configurationPid = "discovery.lgwebos.upnp")
@Component(service = UpnpDiscoveryParticipant.class, configurationPid = "discovery.lgwebos.upnp")
public class LGWebOSUpnpDiscoveryParticipant implements UpnpDiscoveryParticipant {
private final Logger logger = LoggerFactory.getLogger(LGWebOSUpnpDiscoveryParticipant.class);

View File

@ -37,7 +37,7 @@ import org.osgi.service.component.annotations.Reference;
* @author Wouter Born - Add i18n support
*/
@NonNullByDefault
@Component(service = LifxChannelFactory.class, immediate = true)
@Component(service = LifxChannelFactory.class)
public class LifxChannelFactoryImpl implements LifxChannelFactory {
private static final String COLOR_ZONE_LABEL_KEY = "channel-type.lifx.colorzone.label";

View File

@ -59,7 +59,7 @@ import org.slf4j.LoggerFactory;
* @author Karel Goderis - Rewrite for Firmware V2, and remove dependency on external libraries
* @author Wouter Born - Discover light labels, improve locking, optimize packet handling
*/
@Component(immediate = true, service = DiscoveryService.class, configurationPid = "discovery.lifx")
@Component(service = DiscoveryService.class, configurationPid = "discovery.lifx")
@NonNullByDefault
public class LifxLightDiscovery extends AbstractDiscoveryService {

View File

@ -42,7 +42,7 @@ import org.slf4j.LoggerFactory;
*
* @author Thomas Weißschuh - Initial contribution
*/
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.linuxinput")
@Component(service = DiscoveryService.class, configurationPid = "discovery.linuxinput")
@NonNullByDefault
public class LinuxInputDiscoveryService extends AbstractDiscoveryService {

View File

@ -37,7 +37,7 @@ import org.slf4j.LoggerFactory;
* @author Pawel Pieczul - Initial contribution
*
*/
@Component(immediate = true)
@Component
public class LxDiscoveryParticipant implements UpnpDiscoveryParticipant {
private final Logger logger = LoggerFactory.getLogger(LxDiscoveryParticipant.class);

View File

@ -50,7 +50,7 @@ import org.slf4j.LoggerFactory;
* @author Bob Adair - Renamed and added bridge properties
*/
@NonNullByDefault
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.lutron")
@Component(service = DiscoveryService.class, configurationPid = "discovery.lutron")
public class LutronMcastBridgeDiscoveryService extends AbstractDiscoveryService {
private static final int SCAN_INTERVAL_MINUTES = 30;

View File

@ -43,7 +43,7 @@ import org.slf4j.LoggerFactory;
*
* @author Bob Adair - Initial contribution
*/
@Component(immediate = true)
@Component
@NonNullByDefault
public class LutronMdnsBridgeDiscoveryService implements MDNSDiscoveryParticipant {

View File

@ -47,7 +47,7 @@ import org.slf4j.LoggerFactory;
*
* @author Marcel Verpaalen - Initial contribution
*/
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.max")
@Component(service = DiscoveryService.class, configurationPid = "discovery.max")
public class MaxCubeBridgeDiscovery extends AbstractDiscoveryService {
private static final String MAXCUBE_DISCOVER_STRING = "eQ3Max*\0**********I";

View File

@ -41,7 +41,7 @@ import org.slf4j.LoggerFactory;
* @author Martin Lepsy - Added check for Miele gateway for cleaner discovery
*
*/
@Component(immediate = true)
@Component
public class MieleMDNSDiscoveryParticipant implements MDNSDiscoveryParticipant {
private final Logger logger = LoggerFactory.getLogger(MieleMDNSDiscoveryParticipant.class);

View File

@ -40,7 +40,7 @@ import com.google.gson.JsonObject;
* @author Kuba Wolanin - logger fixes
*/
@NonNullByDefault
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.mihome")
@Component(service = DiscoveryService.class, configurationPid = "discovery.mihome")
public class XiaomiBridgeDiscoveryService extends AbstractDiscoveryService implements XiaomiSocketListener {
private static final Set<ThingTypeUID> SUPPORTED_THING_TYPES = Collections.singleton(THING_TYPE_BRIDGE);

View File

@ -51,7 +51,7 @@ import org.slf4j.LoggerFactory;
*
*/
@NonNullByDefault
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.miio")
@Component(service = DiscoveryService.class, configurationPid = "discovery.miio")
public class MiIoDiscovery extends AbstractDiscoveryService {
/** The refresh interval for background discovery */

View File

@ -44,7 +44,7 @@ import org.slf4j.LoggerFactory;
*
*/
@NonNullByDefault
@Component(service = MDNSDiscoveryParticipant.class, immediate = true)
@Component(service = MDNSDiscoveryParticipant.class)
public class MiIoDiscoveryParticipant implements MDNSDiscoveryParticipant {
private final CloudConnector cloudConnector;

View File

@ -57,7 +57,7 @@ import org.slf4j.LoggerFactory;
* @author David Graeff - Initial contribution
*/
@NonNullByDefault
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.milight")
@Component(service = DiscoveryService.class, configurationPid = "discovery.milight")
public class MilightBridgeDiscovery extends AbstractDiscoveryService implements Runnable {
private final Logger logger = LoggerFactory.getLogger(MilightBridgeDiscovery.class);

View File

@ -25,7 +25,7 @@ import org.slf4j.LoggerFactory;
*
* @author David Graeff - Initial contribution
*/
@Component(service = DiscoveryService.class, immediate = true, enabled = false)
@Component(service = DiscoveryService.class, enabled = false)
public class TestDiscovery extends AbstractDiscoveryService {
private final Logger logger = LoggerFactory.getLogger(TestDiscovery.class);

View File

@ -43,7 +43,7 @@ import rx.subscriptions.CompositeSubscription;
*
* @author Mattias Markehed - Initial contribution
*/
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.minecraft")
@Component(service = DiscoveryService.class, configurationPid = "discovery.minecraft")
public class MinecraftDiscoveryService extends AbstractDiscoveryService {
private final Logger logger = LoggerFactory.getLogger(MinecraftDiscoveryService.class);

View File

@ -33,7 +33,7 @@ import org.osgi.service.component.annotations.Component;
*
* @author Mattias Markehed - Initial contribution
*/
@Component(immediate = true)
@Component
public class MinecraftMDNSDiscoveryParticipant implements MDNSDiscoveryParticipant {
@Override

View File

@ -33,7 +33,7 @@ import org.slf4j.LoggerFactory;
* @author Nagy Attila Gabor - initial contribution
*
*/
@Component(immediate = true)
@Component
@NonNullByDefault
public class SunspecDiscoveryParticipant implements ModbusDiscoveryParticipant {

View File

@ -97,7 +97,7 @@ You will have to write a discovery participant class which implements the `Modbu
```java
@Component(immediate = true)
@Component
@NonNullByDefault
public class SunspecDiscoveryParticipant implements ModbusDiscoveryParticipant {
...

View File

@ -44,7 +44,7 @@ import org.slf4j.LoggerFactory;
* @author Nagy Attila Gabor - initial contribution
*
*/
@Component(immediate = true, service = DiscoveryService.class, configurationPid = "discovery.modbus")
@Component(service = DiscoveryService.class, configurationPid = "discovery.modbus")
@NonNullByDefault
public class ModbusDiscoveryService extends AbstractDiscoveryService {

View File

@ -39,7 +39,7 @@ import org.slf4j.LoggerFactory;
*
*/
@NonNullByDefault
@Component(immediate = true)
@Component
public class MPDDiscoveryParticipant implements MDNSDiscoveryParticipant {
private final Logger logger = LoggerFactory.getLogger(MPDDiscoveryParticipant.class);

View File

@ -58,7 +58,7 @@ import com.google.gson.GsonBuilder;
*
* @author David Graeff - Initial contribution
*/
@Component(immediate = true, service = DiscoveryService.class, configurationPid = "discovery.mqttha")
@Component(service = DiscoveryService.class, configurationPid = "discovery.mqttha")
@NonNullByDefault
public class HomeAssistantDiscovery extends AbstractMQTTDiscovery {
@SuppressWarnings("unused")

View File

@ -38,7 +38,7 @@ import org.slf4j.LoggerFactory;
*
* @author David Graeff - Initial contribution
*/
@Component(immediate = true, service = DiscoveryService.class, configurationPid = "discovery.mqtthomie")
@Component(service = DiscoveryService.class, configurationPid = "discovery.mqtthomie")
@NonNullByDefault
public class Homie300Discovery extends AbstractMQTTDiscovery {
private final Logger logger = LoggerFactory.getLogger(Homie300Discovery.class);

View File

@ -38,7 +38,7 @@ import org.slf4j.LoggerFactory;
*
* @author David Graeff - Initial contribution
*/
@Component(immediate = true, service = DiscoveryService.class, configurationPid = "discovery.systemmqttbroker")
@Component(service = DiscoveryService.class, configurationPid = "discovery.systemmqttbroker")
public class MqttServiceDiscoveryService extends AbstractDiscoveryService implements MqttServiceObserver {
private final Logger logger = LoggerFactory.getLogger(MqttServiceDiscoveryService.class);
MqttService mqttService;

View File

@ -42,7 +42,7 @@ import org.slf4j.LoggerFactory;
* @see <a href="https://openhab.org/documentation/development/bindings/discovery-services.html">MSDN
* Discovery</a>
*/
@Component(immediate = true, configurationPid = "discovery.nanoleaf")
@Component(configurationPid = "discovery.nanoleaf")
@NonNullByDefault
public class NanoleafMDNSDiscoveryParticipant implements MDNSDiscoveryParticipant {

View File

@ -43,7 +43,7 @@ import org.slf4j.LoggerFactory;
* @author Tim Roberts - initial contribution
*/
@NonNullByDefault
@Component(immediate = true)
@Component
public class NeeoBrainDiscovery implements MDNSDiscoveryParticipant {
/** The logger */

View File

@ -53,7 +53,7 @@ import org.slf4j.LoggerFactory;
* @author David Graeff - Rewritten
*/
@NonNullByDefault
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.network")
@Component(service = DiscoveryService.class, configurationPid = "discovery.network")
public class NetworkDiscoveryService extends AbstractDiscoveryService implements PresenceDetectionListener {
static final int PING_TIMEOUT_IN_MS = 500;
static final int MAXIMUM_IPS_PER_INTERFACE = 255;

View File

@ -40,7 +40,7 @@ import org.slf4j.LoggerFactory;
*
* @author Mark Herwege - Initial Contribution
*/
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.nikohomecontrol")
@Component(service = DiscoveryService.class, configurationPid = "discovery.nikohomecontrol")
@NonNullByDefault
public class NikoHomeControlBridgeDiscoveryService extends AbstractDiscoveryService {

View File

@ -40,7 +40,7 @@ import org.osgi.service.component.annotations.Reference;
* @author Marcel Verpaalen - Initial contribution
*/
@NonNullByDefault
@Component(service = DiscoveryService.class, immediate = true, configurationPid = "discovery.ntp")
@Component(service = DiscoveryService.class, configurationPid = "discovery.ntp")
public class NtpDiscovery extends AbstractDiscoveryService {
private final TimeZoneProvider timeZoneProvider;

View File

@ -34,8 +34,7 @@ import org.slf4j.LoggerFactory;
* @author Jan N. Klug - Initial contribution
*/
@NonNullByDefault
@Component(service = { DynamicStateDescriptionProvider.class,
OwDynamicStateDescriptionProvider.class }, immediate = true)
@Component(service = { DynamicStateDescriptionProvider.class, OwDynamicStateDescriptionProvider.class })
public class OwDynamicStateDescriptionProvider implements DynamicStateDescriptionProvider {
private final Map<ChannelUID, StateDescription> descriptions = new ConcurrentHashMap<>();

View File

@ -42,7 +42,7 @@ import org.slf4j.LoggerFactory;
* @author Paul Frank - Initial contribution
*/
@NonNullByDefault
@Component(immediate = true)
@Component
public class OnkyoUpnpDiscoveryParticipant implements UpnpDiscoveryParticipant {
private final Logger logger = LoggerFactory.getLogger(OnkyoUpnpDiscoveryParticipant.class);

Some files were not shown because too many files have changed in this diff Show More