Remove Map null annotation workarounds (#8916)
These workarounds to prevent false positives can be removed now the EEAs allow for proper null analysis. Signed-off-by: Wouter Born <github@maindrain.net>
This commit is contained in:
@@ -59,7 +59,7 @@ public class WeatherUndergroundHandlerFactory extends BaseThingHandlerFactory {
|
||||
.of(BRIDGE_THING_TYPES_UIDS, WeatherUndergroundBindingConstants.SUPPORTED_THING_TYPES_UIDS)
|
||||
.flatMap(x -> x.stream()).collect(Collectors.toSet());
|
||||
|
||||
private final Map<ThingUID, @Nullable ServiceRegistration<?>> discoveryServiceRegs = new HashMap<>();
|
||||
private final Map<ThingUID, ServiceRegistration<?>> discoveryServiceRegs = new HashMap<>();
|
||||
|
||||
private final LocaleProvider localeProvider;
|
||||
private final LocationProvider locationProvider;
|
||||
|
||||
@@ -24,8 +24,6 @@ import java.util.Set;
|
||||
import java.util.concurrent.ScheduledFuture;
|
||||
import java.util.concurrent.TimeUnit;
|
||||
|
||||
import org.eclipse.jdt.annotation.NonNull;
|
||||
import org.eclipse.jdt.annotation.Nullable;
|
||||
import org.openhab.binding.weatherunderground.internal.handler.WeatherUndergroundHandler;
|
||||
import org.openhab.core.config.discovery.AbstractDiscoveryService;
|
||||
import org.openhab.core.config.discovery.DiscoveryResultBuilder;
|
||||
@@ -73,7 +71,7 @@ public class WeatherUndergroundDiscoveryService extends AbstractDiscoveryService
|
||||
|
||||
/* We override this method to allow a call from the thing handler factory */
|
||||
@Override
|
||||
public void activate(@Nullable Map<@NonNull String, @Nullable Object> configProperties) {
|
||||
public void activate(Map<String, Object> configProperties) {
|
||||
super.activate(configProperties);
|
||||
}
|
||||
|
||||
|
||||
@@ -87,7 +87,7 @@ public class WeatherUndergroundHandler extends BaseThingHandler {
|
||||
private static final Set<String> USUAL_FEATURES = Stream.of(FEATURE_CONDITIONS, FEATURE_FORECAST10DAY)
|
||||
.collect(Collectors.toSet());
|
||||
|
||||
private static final Map<String, @Nullable String> LANG_ISO_TO_WU_CODES = new HashMap<>();
|
||||
private static final Map<String, String> LANG_ISO_TO_WU_CODES = new HashMap<>();
|
||||
// Codes from https://www.wunderground.com/weather/api/d/docs?d=language-support
|
||||
static {
|
||||
LANG_ISO_TO_WU_CODES.put("AF", "AF");
|
||||
@@ -171,7 +171,7 @@ public class WeatherUndergroundHandler extends BaseThingHandler {
|
||||
// Yiddish - transliterated => JI
|
||||
LANG_ISO_TO_WU_CODES.put("YI", "YI");
|
||||
}
|
||||
private static final Map<String, @Nullable String> LANG_COUNTRY_TO_WU_CODES = new HashMap<>();
|
||||
private static final Map<String, String> LANG_COUNTRY_TO_WU_CODES = new HashMap<>();
|
||||
static {
|
||||
LANG_COUNTRY_TO_WU_CODES.put("en-GB", "LI"); // British English
|
||||
LANG_COUNTRY_TO_WU_CODES.put("fr-CA", "FC"); // French Canadian
|
||||
|
||||
Reference in New Issue
Block a user