Skip to content

Commit

Permalink
Fix formatting issues reported by Spotless
Browse files Browse the repository at this point in the history
  • Loading branch information
rm3l committed Jun 6, 2022
1 parent aa92590 commit ecd3bf4
Show file tree
Hide file tree
Showing 6 changed files with 81 additions and 27 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -111,10 +111,14 @@ public void onClick(View v) {
*/
public interface TabColorizer {

/** @return return the color of the divider drawn to the right of {@code position}. */
/**
* @return return the color of the divider drawn to the right of {@code position}.
*/
int getDividerColor(int position);

/** @return return the color of the indicator used when {@code position} is selected. */
/**
* @return return the color of the indicator used when {@code position} is selected.
*/
int getIndicatorColor(int position);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,9 @@
public abstract class AbstractRouterAction<T>
extends UiRelatedTask<AbstractRouterAction.RouterActionResult<T>> {

/** @param <T> the result type */
/**
* @param <T> the result type
*/
public static class RouterActionResult<T> {

@Nullable private final Exception exception;
Expand Down
16 changes: 12 additions & 4 deletions app/src/main/java/org/rm3l/router_companion/resources/Device.java
Original file line number Diff line number Diff line change
Expand Up @@ -228,7 +228,9 @@ public int getActiveIpConnectionsCount() {
return (activeIpConnections != null ? activeIpConnections.size() : -1);
}

/** @return the alias */
/**
* @return the alias
*/
@Nullable
public String getAlias() {
return alias;
Expand Down Expand Up @@ -270,7 +272,9 @@ public void setDeviceUuidForWol(String deviceUuidForWol) {
this.deviceUuidForWol = deviceUuidForWol;
}

/** @return the IP */
/**
* @return the IP
*/
@Nullable
public String getIpAddress() {
return ipAddress;
Expand All @@ -296,7 +300,9 @@ public void setLastSeen(long lastSeen) {
this.lastSeen = lastSeen;
}

/** @return the MAC */
/**
* @return the MAC
*/
@NonNull
public String getMacAddress() {
return macAddress;
Expand Down Expand Up @@ -339,7 +345,9 @@ public void setRxTotal(double rxTotal) {
this.rxTotal = rxTotal;
}

/** @return the system name */
/**
* @return the system name
*/
@Nullable
public String getSystemName() {
return systemName;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -326,24 +326,32 @@ public enum RouterConnectionProtocol {
this.defaultPassword = defaultPassword;
}

/** @return the channel */
/**
* @return the channel
*/
@NonNull
public String getChannel() {
return channel;
}

/** @return the defaultPassword */
/**
* @return the defaultPassword
*/
@Nullable
public String getDefaultPassword() {
return defaultPassword;
}

/** @return the defaultPort */
/**
* @return the defaultPort
*/
public int getDefaultPort() {
return defaultPort;
}

/** @return the defaultUsername */
/**
* @return the defaultUsername
*/
@Nullable
public String getDefaultUsername() {
return defaultUsername;
Expand Down Expand Up @@ -1218,7 +1226,9 @@ public void setIconPath(String iconPath) {
this.iconPath = iconPath;
}

/** @return the internal DB id */
/**
* @return the internal DB id
*/
public int getId() {
return id;
}
Expand Down Expand Up @@ -1257,7 +1267,9 @@ public Collection<LocalSSIDLookup> getLocalSSIDLookupData(@NonNull final Context
return localSSIDLookups;
}

/** @return the name */
/**
* @return the name
*/
@Nullable
public String getName() {
return name;
Expand Down Expand Up @@ -1289,13 +1301,17 @@ public Router setOrderIndex(int orderIndex) {
return this;
}

/** @return the password */
/**
* @return the password
*/
@Nullable
public String getPassword() {
return password;
}

/** @return the password */
/**
* @return the password
*/
@Nullable
public String getPasswordPlain() {
return password != null ? d(password) : null;
Expand All @@ -1306,19 +1322,25 @@ public SharedPreferences getPreferences(@Nullable final Context ctx) {
return getPreferences(this, ctx);
}

/** @return the privKey */
/**
* @return the privKey
*/
@Nullable
public String getPrivKey() {
return privKey;
}

/** @return the decrypted privKey */
/**
* @return the decrypted privKey
*/
@Nullable
public String getPrivKeyPlain() {
return privKey != null ? d(privKey) : null;
}

/** @return the remoteIpAddress */
/**
* @return the remoteIpAddress
*/
@NonNull
public String getRemoteIpAddress() {
return remoteIpAddress;
Expand All @@ -1336,7 +1358,9 @@ public Router setRemoteIpAddress(@NonNull final String remoteIpAddress) {
return this;
}

/** @return the remotePort, if any, or the default port for the routerConnectionProtocol */
/**
* @return the remotePort, if any, or the default port for the routerConnectionProtocol
*/
public int getRemotePort() {
return remotePort <= 0 ? this.routerConnectionProtocol.getDefaultPort() : remotePort;
}
Expand All @@ -1353,7 +1377,9 @@ public Router setRemotePort(final int remotePort) {
return this;
}

/** @return the RouterConnectionProtocol */
/**
* @return the RouterConnectionProtocol
*/
@NonNull
public RouterConnectionProtocol getRouterConnectionProtocol() {
return routerConnectionProtocol;
Expand Down Expand Up @@ -1442,19 +1468,25 @@ public String getTemplateUuidOrUuid() {
return templateUuid != null ? templateUuid : uuid;
}

/** @return the username */
/**
* @return the username
*/
@NonNull
public String getUsername() {
return username;
}

/** @return the unencrypted username */
/**
* @return the unencrypted username
*/
@Nullable
public String getUsernamePlain() {
return d(username);
}

/** @return the uuid */
/**
* @return the uuid
*/
@NonNull
public String getUuid() {
return uuid;
Expand Down Expand Up @@ -1505,7 +1537,9 @@ public boolean isFallbackToPrimaryAddr(@Nullable final Context ctx) {
return sharedPreferences.getBoolean(FALLBACK_TO_PRIMARY_ADDR, false);
}

/** @return whether the strictHostKeyChecking flag is on or off */
/**
* @return whether the strictHostKeyChecking flag is on or off
*/
public boolean isStrictHostKeyChecking() {
return strictHostKeyChecking;
}
Expand Down Expand Up @@ -1630,7 +1664,9 @@ public RouterInfo toRouterInfo() {
.setDemoRouter(Utils.isDemoRouter(this));
}

/** @return the Router string representation */
/**
* @return the Router string representation
*/
@Override
@NonNull
public String toString() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -999,7 +999,9 @@ private static int checkAck(@NonNull final InputStream in) throws IOException {
return b;
}

/** @throws java.io.IOException */
/**
* @throws java.io.IOException
*/
private static boolean closeChannel(
@NonNull final Channel channel, @Nullable final OutputStream out) throws IOException {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,9 @@ public static String getPackageNameToUse(Context context) {
return sPackageNameToUse;
}

/** @return All possible chrome package names that provide custom tabs feature. */
/**
* @return All possible chrome package names that provide custom tabs feature.
*/
public static String[] getPackages() {
return new String[] {"", STABLE_PACKAGE, BETA_PACKAGE, DEV_PACKAGE, LOCAL_PACKAGE};
}
Expand Down

0 comments on commit ecd3bf4

Please sign in to comment.