Remove redundant modifiers from interfaces (#14843)
Signed-off-by: Wouter Born <github@maindrain.net>
This commit is contained in:
@@ -34,104 +34,104 @@ import org.openhab.binding.shelly.internal.config.ShellyThingConfiguration;
|
||||
*/
|
||||
@NonNullByDefault
|
||||
public interface ShellyApiInterface {
|
||||
public boolean isInitialized();
|
||||
boolean isInitialized();
|
||||
|
||||
public void initialize() throws ShellyApiException;
|
||||
void initialize() throws ShellyApiException;
|
||||
|
||||
public void setConfig(String thingName, ShellyThingConfiguration config);
|
||||
void setConfig(String thingName, ShellyThingConfiguration config);
|
||||
|
||||
public ShellySettingsDevice getDeviceInfo() throws ShellyApiException;
|
||||
ShellySettingsDevice getDeviceInfo() throws ShellyApiException;
|
||||
|
||||
public ShellyDeviceProfile getDeviceProfile(String thingType) throws ShellyApiException;
|
||||
ShellyDeviceProfile getDeviceProfile(String thingType) throws ShellyApiException;
|
||||
|
||||
public ShellySettingsStatus getStatus() throws ShellyApiException;
|
||||
ShellySettingsStatus getStatus() throws ShellyApiException;
|
||||
|
||||
public void setLedStatus(String ledName, Boolean value) throws ShellyApiException;
|
||||
void setLedStatus(String ledName, Boolean value) throws ShellyApiException;
|
||||
|
||||
public void setSleepTime(int value) throws ShellyApiException;
|
||||
void setSleepTime(int value) throws ShellyApiException;
|
||||
|
||||
public ShellyStatusRelay getRelayStatus(int relayIndex) throws ShellyApiException;
|
||||
ShellyStatusRelay getRelayStatus(int relayIndex) throws ShellyApiException;
|
||||
|
||||
public void setRelayTurn(int id, String turnMode) throws ShellyApiException;
|
||||
void setRelayTurn(int id, String turnMode) throws ShellyApiException;
|
||||
|
||||
public ShellyRollerStatus getRollerStatus(int rollerIndex) throws ShellyApiException;
|
||||
ShellyRollerStatus getRollerStatus(int rollerIndex) throws ShellyApiException;
|
||||
|
||||
public void setRollerTurn(int relayIndex, String turnMode) throws ShellyApiException;
|
||||
void setRollerTurn(int relayIndex, String turnMode) throws ShellyApiException;
|
||||
|
||||
public void setRollerPos(int relayIndex, int position) throws ShellyApiException;
|
||||
void setRollerPos(int relayIndex, int position) throws ShellyApiException;
|
||||
|
||||
public void setAutoTimer(int index, String timerName, double value) throws ShellyApiException;
|
||||
void setAutoTimer(int index, String timerName, double value) throws ShellyApiException;
|
||||
|
||||
public ShellyStatusSensor getSensorStatus() throws ShellyApiException;
|
||||
ShellyStatusSensor getSensorStatus() throws ShellyApiException;
|
||||
|
||||
public ShellyStatusLight getLightStatus() throws ShellyApiException;
|
||||
ShellyStatusLight getLightStatus() throws ShellyApiException;
|
||||
|
||||
public ShellyShortLightStatus getLightStatus(int index) throws ShellyApiException;
|
||||
ShellyShortLightStatus getLightStatus(int index) throws ShellyApiException;
|
||||
|
||||
public void setLightMode(String mode) throws ShellyApiException;
|
||||
void setLightMode(String mode) throws ShellyApiException;
|
||||
|
||||
public void setLightParm(int lightIndex, String parm, String value) throws ShellyApiException;
|
||||
void setLightParm(int lightIndex, String parm, String value) throws ShellyApiException;
|
||||
|
||||
public void setLightParms(int lightIndex, Map<String, String> parameters) throws ShellyApiException;
|
||||
void setLightParms(int lightIndex, Map<String, String> parameters) throws ShellyApiException;
|
||||
|
||||
public ShellyShortLightStatus setLightTurn(int id, String turnMode) throws ShellyApiException;
|
||||
ShellyShortLightStatus setLightTurn(int id, String turnMode) throws ShellyApiException;
|
||||
|
||||
public void setBrightness(int id, int brightness, boolean autoOn) throws ShellyApiException;
|
||||
void setBrightness(int id, int brightness, boolean autoOn) throws ShellyApiException;
|
||||
|
||||
// Valve
|
||||
public void setValveMode(int id, boolean auto) throws ShellyApiException;
|
||||
void setValveMode(int id, boolean auto) throws ShellyApiException;
|
||||
|
||||
public void setValveTemperature(int valveId, int value) throws ShellyApiException;
|
||||
void setValveTemperature(int valveId, int value) throws ShellyApiException;
|
||||
|
||||
public void setValveProfile(int valveId, int value) throws ShellyApiException;
|
||||
void setValveProfile(int valveId, int value) throws ShellyApiException;
|
||||
|
||||
public void setValvePosition(int valveId, double value) throws ShellyApiException;
|
||||
void setValvePosition(int valveId, double value) throws ShellyApiException;
|
||||
|
||||
public void setValveBoostTime(int valveId, int value) throws ShellyApiException;
|
||||
void setValveBoostTime(int valveId, int value) throws ShellyApiException;
|
||||
|
||||
public void startValveBoost(int valveId, int value) throws ShellyApiException;
|
||||
void startValveBoost(int valveId, int value) throws ShellyApiException;
|
||||
|
||||
public ShellyOtaCheckResult checkForUpdate() throws ShellyApiException;
|
||||
ShellyOtaCheckResult checkForUpdate() throws ShellyApiException;
|
||||
|
||||
public ShellySettingsUpdate firmwareUpdate(String uri) throws ShellyApiException;
|
||||
ShellySettingsUpdate firmwareUpdate(String uri) throws ShellyApiException;
|
||||
|
||||
public ShellySettingsLogin getLoginSettings() throws ShellyApiException;
|
||||
ShellySettingsLogin getLoginSettings() throws ShellyApiException;
|
||||
|
||||
public ShellySettingsLogin setLoginCredentials(String user, String password) throws ShellyApiException;
|
||||
ShellySettingsLogin setLoginCredentials(String user, String password) throws ShellyApiException;
|
||||
|
||||
public String setWiFiRecovery(boolean enable) throws ShellyApiException;
|
||||
String setWiFiRecovery(boolean enable) throws ShellyApiException;
|
||||
|
||||
public boolean setWiFiRangeExtender(boolean enable) throws ShellyApiException;
|
||||
boolean setWiFiRangeExtender(boolean enable) throws ShellyApiException;
|
||||
|
||||
public boolean setEthernet(boolean enable) throws ShellyApiException;
|
||||
boolean setEthernet(boolean enable) throws ShellyApiException;
|
||||
|
||||
public boolean setBluetooth(boolean enable) throws ShellyApiException;
|
||||
boolean setBluetooth(boolean enable) throws ShellyApiException;
|
||||
|
||||
public String deviceReboot() throws ShellyApiException;
|
||||
String deviceReboot() throws ShellyApiException;
|
||||
|
||||
public String setDebug(boolean enabled) throws ShellyApiException;
|
||||
String setDebug(boolean enabled) throws ShellyApiException;
|
||||
|
||||
public String getDebugLog(String id) throws ShellyApiException;
|
||||
String getDebugLog(String id) throws ShellyApiException;
|
||||
|
||||
public String setCloud(boolean enabled) throws ShellyApiException;
|
||||
String setCloud(boolean enabled) throws ShellyApiException;
|
||||
|
||||
public String setApRoaming(boolean enable) throws ShellyApiException;
|
||||
String setApRoaming(boolean enable) throws ShellyApiException;
|
||||
|
||||
public String factoryReset() throws ShellyApiException;
|
||||
String factoryReset() throws ShellyApiException;
|
||||
|
||||
public String resetStaCache() throws ShellyApiException;
|
||||
String resetStaCache() throws ShellyApiException;
|
||||
|
||||
public int getTimeoutsRecovered();
|
||||
int getTimeoutsRecovered();
|
||||
|
||||
public int getTimeoutErrors();
|
||||
int getTimeoutErrors();
|
||||
|
||||
public String getCoIoTDescription() throws ShellyApiException;
|
||||
String getCoIoTDescription() throws ShellyApiException;
|
||||
|
||||
public ShellySettingsLogin setCoIoTPeer(String peer) throws ShellyApiException;
|
||||
ShellySettingsLogin setCoIoTPeer(String peer) throws ShellyApiException;
|
||||
|
||||
public void setActionURLs() throws ShellyApiException;
|
||||
void setActionURLs() throws ShellyApiException;
|
||||
|
||||
public void sendIRKey(String keyCode) throws ShellyApiException, IllegalArgumentException;
|
||||
void sendIRKey(String keyCode) throws ShellyApiException, IllegalArgumentException;
|
||||
|
||||
public void close();
|
||||
void close();
|
||||
}
|
||||
|
||||
@@ -30,14 +30,14 @@ import org.openhab.core.types.State;
|
||||
*/
|
||||
@NonNullByDefault
|
||||
public interface Shelly1CoIoTInterface {
|
||||
public int getVersion();
|
||||
int getVersion();
|
||||
|
||||
public CoIotDescrSen fixDescription(@Nullable CoIotDescrSen sen, Map<String, CoIotDescrBlk> blkMap);
|
||||
CoIotDescrSen fixDescription(@Nullable CoIotDescrSen sen, Map<String, CoIotDescrBlk> blkMap);
|
||||
|
||||
public void completeMissingSensorDefinition(Map<String, CoIotDescrSen> sensorMap);
|
||||
void completeMissingSensorDefinition(Map<String, CoIotDescrSen> sensorMap);
|
||||
|
||||
public boolean handleStatusUpdate(List<CoIotSensor> sensorUpdates, CoIotDescrSen sen, int serial, CoIotSensor s,
|
||||
boolean handleStatusUpdate(List<CoIotSensor> sensorUpdates, CoIotDescrSen sen, int serial, CoIotSensor s,
|
||||
Map<String, State> updates, ShellyColorUtils col);
|
||||
|
||||
public String getLastWakeup();
|
||||
String getLastWakeup();
|
||||
}
|
||||
|
||||
@@ -23,5 +23,5 @@ import org.eclipse.jdt.annotation.Nullable;
|
||||
*/
|
||||
@NonNullByDefault
|
||||
public interface Shelly1CoapListener {
|
||||
public void processResponse(@Nullable Response response);
|
||||
void processResponse(@Nullable Response response);
|
||||
}
|
||||
|
||||
@@ -24,15 +24,15 @@ import org.openhab.binding.shelly.internal.api2.Shelly2ApiJsonDTO.Shelly2RpcNoti
|
||||
@NonNullByDefault
|
||||
public interface Shelly2RpctInterface {
|
||||
|
||||
public void onConnect(String deviceIp, boolean connected);
|
||||
void onConnect(String deviceIp, boolean connected);
|
||||
|
||||
public void onMessage(String decodedmessage);
|
||||
void onMessage(String decodedmessage);
|
||||
|
||||
public void onNotifyStatus(Shelly2RpcNotifyStatus message);
|
||||
void onNotifyStatus(Shelly2RpcNotifyStatus message);
|
||||
|
||||
public void onNotifyEvent(Shelly2RpcNotifyEvent message);
|
||||
void onNotifyEvent(Shelly2RpcNotifyEvent message);
|
||||
|
||||
public void onClose(int statusCode, String reason);
|
||||
void onClose(int statusCode, String reason);
|
||||
|
||||
public void onError(Throwable cause);
|
||||
void onError(Throwable cause);
|
||||
}
|
||||
|
||||
@@ -28,6 +28,6 @@ public interface ShellyDeviceListener {
|
||||
/**
|
||||
* This method is called when new device information is received.
|
||||
*/
|
||||
public boolean onEvent(String ipAddress, String deviceName, String deviceIndex, String eventType,
|
||||
boolean onEvent(String ipAddress, String deviceName, String deviceIndex, String eventType,
|
||||
Map<String, String> parameters);
|
||||
}
|
||||
|
||||
@@ -28,29 +28,29 @@ import org.openhab.core.types.State;
|
||||
@NonNullByDefault
|
||||
public interface ShellyManagerInterface {
|
||||
|
||||
public Thing getThing();
|
||||
Thing getThing();
|
||||
|
||||
public String getThingName();
|
||||
String getThingName();
|
||||
|
||||
public ShellyDeviceProfile getProfile();
|
||||
ShellyDeviceProfile getProfile();
|
||||
|
||||
public ShellyDeviceProfile getProfile(boolean forceRefresh) throws ShellyApiException;
|
||||
ShellyDeviceProfile getProfile(boolean forceRefresh) throws ShellyApiException;
|
||||
|
||||
public ShellyApiInterface getApi();
|
||||
ShellyApiInterface getApi();
|
||||
|
||||
public ShellyDeviceStats getStats();
|
||||
ShellyDeviceStats getStats();
|
||||
|
||||
public void resetStats();
|
||||
void resetStats();
|
||||
|
||||
public State getChannelValue(String group, String channel);
|
||||
State getChannelValue(String group, String channel);
|
||||
|
||||
public void setThingOnline();
|
||||
void setThingOnline();
|
||||
|
||||
public void setThingOffline(ThingStatusDetail detail, String messageKey, Object... arguments);
|
||||
void setThingOffline(ThingStatusDetail detail, String messageKey, Object... arguments);
|
||||
|
||||
public boolean requestUpdates(int requestCount, boolean refreshSettings);
|
||||
boolean requestUpdates(int requestCount, boolean refreshSettings);
|
||||
|
||||
public void incProtMessages();
|
||||
void incProtMessages();
|
||||
|
||||
public void incProtErrors();
|
||||
void incProtErrors();
|
||||
}
|
||||
|
||||
@@ -39,81 +39,82 @@ import org.openhab.core.types.StateOption;
|
||||
@NonNullByDefault
|
||||
public interface ShellyThingInterface {
|
||||
|
||||
public ShellyDeviceProfile getProfile(boolean forceRefresh) throws ShellyApiException;
|
||||
ShellyDeviceProfile getProfile(boolean forceRefresh) throws ShellyApiException;
|
||||
|
||||
public @Nullable List<StateOption> getStateOptions(ChannelTypeUID uid);
|
||||
@Nullable
|
||||
List<StateOption> getStateOptions(ChannelTypeUID uid);
|
||||
|
||||
public double getChannelDouble(String group, String channel);
|
||||
double getChannelDouble(String group, String channel);
|
||||
|
||||
public boolean updateChannel(String group, String channel, State value);
|
||||
boolean updateChannel(String group, String channel, State value);
|
||||
|
||||
public boolean updateChannel(String channelId, State value, boolean force);
|
||||
boolean updateChannel(String channelId, State value, boolean force);
|
||||
|
||||
public void setThingOnline();
|
||||
void setThingOnline();
|
||||
|
||||
public void setThingOffline(ThingStatusDetail detail, String messageKey, Object... arguments);
|
||||
void setThingOffline(ThingStatusDetail detail, String messageKey, Object... arguments);
|
||||
|
||||
public String getThingType();
|
||||
String getThingType();
|
||||
|
||||
public ThingStatus getThingStatus();
|
||||
ThingStatus getThingStatus();
|
||||
|
||||
public ThingStatusDetail getThingStatusDetail();
|
||||
ThingStatusDetail getThingStatusDetail();
|
||||
|
||||
public boolean isThingOnline();
|
||||
boolean isThingOnline();
|
||||
|
||||
public boolean requestUpdates(int requestCount, boolean refreshSettings);
|
||||
boolean requestUpdates(int requestCount, boolean refreshSettings);
|
||||
|
||||
public void triggerUpdateFromCoap();
|
||||
void triggerUpdateFromCoap();
|
||||
|
||||
public void reinitializeThing();
|
||||
void reinitializeThing();
|
||||
|
||||
public void restartWatchdog();
|
||||
void restartWatchdog();
|
||||
|
||||
public void publishState(String channelId, State value);
|
||||
void publishState(String channelId, State value);
|
||||
|
||||
public boolean areChannelsCreated();
|
||||
boolean areChannelsCreated();
|
||||
|
||||
public State getChannelValue(String group, String channel);
|
||||
State getChannelValue(String group, String channel);
|
||||
|
||||
public boolean updateInputs(ShellySettingsStatus status);
|
||||
boolean updateInputs(ShellySettingsStatus status);
|
||||
|
||||
public void updateChannelDefinitions(Map<String, Channel> dynChannels);
|
||||
void updateChannelDefinitions(Map<String, Channel> dynChannels);
|
||||
|
||||
public void postEvent(String event, boolean force);
|
||||
void postEvent(String event, boolean force);
|
||||
|
||||
public void triggerChannel(String group, String channelID, String event);
|
||||
void triggerChannel(String group, String channelID, String event);
|
||||
|
||||
public void triggerButton(String group, int idx, String value);
|
||||
void triggerButton(String group, int idx, String value);
|
||||
|
||||
public ShellyDeviceStats getStats();
|
||||
ShellyDeviceStats getStats();
|
||||
|
||||
public void resetStats();
|
||||
void resetStats();
|
||||
|
||||
public Thing getThing();
|
||||
Thing getThing();
|
||||
|
||||
public String getThingName();
|
||||
String getThingName();
|
||||
|
||||
public ShellyThingConfiguration getThingConfig();
|
||||
ShellyThingConfiguration getThingConfig();
|
||||
|
||||
public HttpClient getHttpClient();
|
||||
HttpClient getHttpClient();
|
||||
|
||||
public String getProperty(String key);
|
||||
String getProperty(String key);
|
||||
|
||||
public void updateProperties(String key, String value);
|
||||
void updateProperties(String key, String value);
|
||||
|
||||
public boolean updateWakeupReason(@Nullable List<Object> valueArray);
|
||||
boolean updateWakeupReason(@Nullable List<Object> valueArray);
|
||||
|
||||
public ShellyApiInterface getApi();
|
||||
ShellyApiInterface getApi();
|
||||
|
||||
public ShellyDeviceProfile getProfile();
|
||||
ShellyDeviceProfile getProfile();
|
||||
|
||||
public long getScheduledUpdates();
|
||||
long getScheduledUpdates();
|
||||
|
||||
public void fillDeviceStatus(ShellySettingsStatus status, boolean updated);
|
||||
void fillDeviceStatus(ShellySettingsStatus status, boolean updated);
|
||||
|
||||
public boolean checkRepresentation(String key);
|
||||
boolean checkRepresentation(String key);
|
||||
|
||||
public void incProtMessages();
|
||||
void incProtMessages();
|
||||
|
||||
public void incProtErrors();
|
||||
void incProtErrors();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user