public abstract class AisPacketFiltersBase extends Object implements FilterPredicateFactory
| Constructor and Description |
|---|
AisPacketFiltersBase() |
| Modifier and Type | Method and Description |
|---|---|
protected static boolean |
compare(float lhs,
float rhs,
CompareToOperator operator)
Compare the left-hand side value to the right-hand side value using the specified operator.
|
protected static boolean |
compare(int lhs,
int rhs,
CompareToOperator operator)
Compare the left-hand side value to the right-hand side value using the specified operator.
|
protected static boolean |
compare(String lhs,
String rhs,
CompareToOperator operator)
Lexically compare the left-hand side value to the right-hand side value using the specified operator.
|
protected static boolean |
inRange(float min,
float max,
float value)
Test if the floating point value is in the closed range between min and max.
|
protected static boolean |
inRange(int min,
int max,
int value)
Test if the integer value is in the closed range between min and max.
|
protected static <T> boolean |
matchesGlob(T value,
String glob)
Test of the string representation of the supplied value matches the given glob expression.
|
protected static String |
preprocessAisString(String aisString)
Convert an AIS string to a Java string.
|
protected static String |
preprocessExpressionString(String string)
Remove an optional pair of apostrophes around the string.
|
protected static String[] |
preprocessExpressionStrings(String[] strings)
Remove an optional pair of apostrophes around each string in an array of strings.
|
protected static final String preprocessAisString(String aisString)
aisString - the AIS stringprotected static final String preprocessExpressionString(String string)
string - the stringprotected static final String[] preprocessExpressionStrings(String[] strings)
strings - the stringsprotected static final boolean compare(String lhs, String rhs, CompareToOperator operator)
lhs - the value of the left-hand side.rhs - the value of the right-hand side.operator - the binary operator to apply for the comparison.protected static final boolean compare(int lhs,
int rhs,
CompareToOperator operator)
lhs - the value of the left-hand side.rhs - the value of the right-hand side.operator - the binary operator to apply for the comparison.protected static final boolean compare(float lhs,
float rhs,
CompareToOperator operator)
lhs - the value of the left-hand side.rhs - the value of the right-hand side.operator - the binary operator to apply for the comparison.protected static final boolean inRange(int min,
int max,
int value)
min - the minmax - the maxvalue - the valueprotected static final boolean inRange(float min,
float max,
float value)
min - the minmax - the maxvalue - the valueprotected static final <T> boolean matchesGlob(T value,
String glob)
T - the type parametervalue - the valueglob - the globCopyright © 2011–2019 Danish Maritime Authority. All rights reserved.