Improve javadoc for all addons (#15667)

Signed-off-by: Holger Friedrich <mail@holger-friedrich.de>
This commit is contained in:
Holger Friedrich
2023-09-30 21:49:12 +02:00
committed by GitHub
parent 0039e391cd
commit cbf4411034
618 changed files with 1106 additions and 1110 deletions

View File

@@ -161,7 +161,7 @@ public class LcnModuleActions implements ThingActions {
/**
* Start an lcn relay timer with the given duration [ms]
*
* @param relaynumber 1-based number of the relay to use
* @param relayNumber 1-based number of the relay to use
* @param duration duration of the relay timer in milliseconds
*/
@RuleAction(label = "start a relay timer", description = "Start an LCN relay timer.")
@@ -178,7 +178,7 @@ public class LcnModuleActions implements ThingActions {
/**
* Let the beeper connected to the LCN module beep.
*
* @param volume sound volume in percent. Can be null. Then, the last volume is used.
* @param soundVolume sound volume in percent. Can be null. Then, the last volume is used.
* @param tonality N=normal, S=special, 1-7 tonalities 1-7. Can be null. Then, normal tonality is used.
* @param count number of beeps. Can be null. Then, number of beeps is one.
*/

View File

@@ -354,9 +354,9 @@ public class LcnModuleHandler extends BaseThingHandler {
}
/**
* Updates the LCN module's serial number property.
* Updates the LCN module's firmware version property.
*
* @param serialNumber the new serial number
* @param firmwareVersion the new firmware version
*/
public void updateFirmwareVersionProperty(String firmwareVersion) {
updateProperty(Thing.PROPERTY_FIRMWARE_VERSION, firmwareVersion);

View File

@@ -49,7 +49,8 @@ public abstract class LcnAddr {
* Gets the physical segment id ("local" segment replaced with 0).
* Can be used to send data into the LCN bus.
*
* @param localSegegmentId the segment id of the local segment (managed by {@link Connection})
* @param localSegegmentId the segment id of the local segment (managed by
* {@link org.openhab.binding.lcn.internal.connection.Connection})
* @return the physical segment id
*/
public int getPhysicalSegmentId(int localSegegmentId) {

View File

@@ -160,7 +160,7 @@ public final class LcnDefs {
/**
* Generates an array of booleans from an input integer (actually a byte).
*
* @param input the input byte (0..255)
* @param inputByte the input byte (0..255)
* @return the array of 8 booleans
* @throws IllegalArgumentException if input is out of range (not a byte)
*/

View File

@@ -34,7 +34,8 @@ public final class PckGenerator {
/**
* Generates a keep-alive.
* LCN-PCHK will close the connection if it does not receive any commands from
* an open {@link Connection} for a specific period (10 minutes by default).
* an open {@link org.openhab.binding.lcn.internal.connection.Connection} for a specific period
* (10 minutes by default).
*
* @param counter the current ping's id (optional, but "best practice"). Should start with 1
* @return the PCK command as text
@@ -177,7 +178,7 @@ public final class PckGenerator {
* Generates a control command for switching all outputs ON or OFF with a fixed ramp of 0.5s.
*
* @param percent 0..100
* @returnthe PCK command (without address header) as text
* @return the PCK command (without address header) as text
*/
public static String controlAllOutputs(double percent) {
return String.format("AH%03d", Math.round(percent));
@@ -398,7 +399,6 @@ public final class PckGenerator {
* @param number regulator number 0..1
* @param value the absolute value to set
* @return the PCK command (without address header) as text
* @throws LcnException
*/
public static String setSetpointAbsolute(int number, int value) {
int internalValue = value;
@@ -447,7 +447,6 @@ public final class PckGenerator {
* @param type the reference-point
* @param value the native LCN value to add/subtract (can be negative)
* @return the PCK command (without address header) as text
* @throws LcnException if command is not supported
*/
public static String setVariableRelative(Variable variable, LcnDefs.RelVarRef type, int value) {
if (variable.getNumber() == 0) {
@@ -844,7 +843,8 @@ public final class PckGenerator {
/**
* Generates a command to let the beeper connected to the LCN module beep.
*
* @param volume the sound volume
* @param tonality N=normal, S=special, 1-7 tonalities 1-7.
* @param count count number of beeps.
* @return the PCK command (without address header) as text
* @throws LcnException if out of range
*/

View File

@@ -240,8 +240,7 @@ public enum Variable {
* Checks if the target LCN module would automatically send status-updates if
* the given variable type was changed by command.
*
* @param variable the variable type to check
* @param is2013 the target module's-generation
* @param firmwareVersion
* @return true if a poll is required to get the new status-value
*/
@SuppressWarnings("PMD.SimplifyBooleanReturns")

View File

@@ -407,7 +407,7 @@ public class Connection {
/**
* Gets the SocketChannel of the Connection.
*
* @returnthe socket channel
* @return the socket channel
*/
@Nullable
public Channel getSocketChannel() {

View File

@@ -49,7 +49,7 @@ public class Converter {
/**
* Converts a human readable value into LCN native value.
*
* @param humanReadable value to convert
* @param quantityType value to convert
* @return the native LCN value
* @throws LcnException when the value could not be converted to the base unit
*/

View File

@@ -74,7 +74,7 @@ public class ValueConverter extends Converter {
/**
* Converts a human readable value into LCN native value.
*
* @param humanReadable value to convert
* @param quantityType value to convert
* @return the native LCN value
* @throws LcnException when the value could not be converted to the base unit
*/

View File

@@ -117,7 +117,6 @@ public abstract class AbstractLcnModuleSubHandler implements ILcnModuleSubHandle
* message.
*
* @param pck the message to process
* @return true, if the message could be processed successfully
*/
public void tryParse(String pck) {
getPckStatusMessagePatterns().stream() //