Package com.google.common.base
Class Platform
java.lang.Object
com.google.common.base.Platform
Methods factored out so that they can be emulated differently in GWT.
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final Logger
private static final PatternCompiler
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription(package private) static CommonPattern
compilePattern
(String pattern) (package private) static String
emptyToNull
(String string) Returns the string if it is not empty, or a null string otherwise.(package private) static String
formatCompact4Digits
(double value) getEnumIfPresent
(Class<T> enumClass, String value) private static PatternCompiler
private static void
(package private) static String
nullToEmpty
(String string) Returns the string if it is not null, or an empty string otherwise.(package private) static boolean
(package private) static CharMatcher
precomputeCharMatcher
(CharMatcher matcher) (package private) static boolean
stringIsNullOrEmpty
(String string)
-
Field Details
-
logger
-
patternCompiler
-
-
Constructor Details
-
Platform
private Platform()
-
-
Method Details
-
precomputeCharMatcher
-
getEnumIfPresent
-
formatCompact4Digits
-
stringIsNullOrEmpty
-
nullToEmpty
Returns the string if it is not null, or an empty string otherwise.- Parameters:
string
- the string to test and possibly return- Returns:
string
if it is not null;""
otherwise
-
emptyToNull
Returns the string if it is not empty, or a null string otherwise.- Parameters:
string
- the string to test and possibly return- Returns:
string
if it is not empty;null
otherwise
-
compilePattern
-
patternCompilerIsPcreLike
static boolean patternCompilerIsPcreLike() -
loadPatternCompiler
-
logPatternCompilerError
-