Class Platform
java.lang.Object
com.google.common.truth.Platform
Extracted routines that need to be swapped in for GWT, to allow for
minimal deltas between the GWT and non-GWT version.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate static voidaddInterfaceNames(Class<?>[] interfaces, Set<String> types) private static voidaddTypeNames(Class<?> clazz, Set<String> types) static AssertionErrorcomparisonFailure(String message, String expected, String actual) static StringcompressType(String type) Inspired by JavaWriter.static booleanisInstanceOfType(Object instance, Class<?> clazz) Returns true if the instance is assignable to the type Clazz.(package private) static booleanisInstanceOfTypeGWT(Object instance, Class<?> clazz) Returns true if the instance is assignable to the type Clazz (suitable for a GWT environment).(package private) static booleanisInstanceOfTypeJava(Object instance, Class<?> clazz) Returns true if the instance is assignable to the type Clazz (suitable for a JVM environment).private static StringstripIfInPackage(String type, String packagePrefix) private static StringstripIfPrefixed(String string, String prefix) private static String
-
Field Details
-
TYPE_PATTERN
-
-
Constructor Details
-
Platform
private Platform()
-
-
Method Details
-
isInstanceOfType
-
isInstanceOfTypeJava
-
isInstanceOfTypeGWT
-
addInterfaceNames
-
addTypeNames
-
compressType
-
typeOnly
-
stripIfPrefixed
-
stripIfInPackage
-
comparisonFailure
-