mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-25 01:41:43 +00:00
Java optimization and formatting fixes (#4857)
This commit is contained in:
@@ -118,8 +118,10 @@ public enum NetworkTableType {
|
||||
} else if (data instanceof Float) {
|
||||
return "float";
|
||||
} else if (data instanceof Long) {
|
||||
// Checking Long because NT supports 64-bit integers
|
||||
return "int";
|
||||
} else if (data instanceof Double || data instanceof Number) {
|
||||
// If typeof Number class, return "double" as the type. Functions as a "catch-all".
|
||||
return "double";
|
||||
} else if (data instanceof String) {
|
||||
return "string";
|
||||
@@ -130,6 +132,7 @@ public enum NetworkTableType {
|
||||
} else if (data instanceof long[] || data instanceof Long[]) {
|
||||
return "int[]";
|
||||
} else if (data instanceof double[] || data instanceof Double[] || data instanceof Number[]) {
|
||||
// If typeof Number class, return "double[]" as the type. Functions as a "catch-all".
|
||||
return "double[]";
|
||||
} else if (data instanceof String[]) {
|
||||
return "string[]";
|
||||
|
||||
@@ -15,7 +15,7 @@ public class PubSubOption {
|
||||
disableRemote,
|
||||
disableLocal,
|
||||
excludePublisher,
|
||||
excludeSelf;
|
||||
excludeSelf
|
||||
}
|
||||
|
||||
PubSubOption(Kind kind, boolean value) {
|
||||
|
||||
Reference in New Issue
Block a user