Package org.dalesbred.internal.utils
Class Primitives
java.lang.Object
org.dalesbred.internal.utils.Primitives
Utilities for handling primitive types and their wrappers uniformly.
-
Method Summary
Modifier and TypeMethodDescriptionstatic @NotNull Object[]
arrayAsObjectArray
(@NotNull Object o) static <T> @NotNull Class<T>
Returns the corresponding primitive type for a wrapper type, or the type itself if it is not a wrapper.static <T> @NotNull Class<T>
Returns the corresponding wrapper type for a primitive type, or the type itself if it is not a primitive type.static @NotNull Type
-
Method Details
-
wrap
Returns the corresponding wrapper type for a primitive type, or the type itself if it is not a primitive type. -
wrap
-
unwrap
Returns the corresponding primitive type for a wrapper type, or the type itself if it is not a wrapper. -
arrayAsObjectArray
-