public class ShortCachedClass
extends NumberCachedClass
Provides optimized reflection caching for short and Short.
Coerces numeric arguments to short values for type-safe method invocation.
Optionally allows null values for the boxed Short class variant.
| Fields inherited from class | Fields |
|---|---|
class CachedClass |
EMPTY_ARRAY, classInfo, isArray, isInterface, isNumber, isPrimitive, modifiers, mopMethods |
| Constructor and description |
|---|
ShortCachedClass(Class klazz, ClassInfo classInfo, boolean allowNull)Constructs a cached class representation for the given short class. |
| Type Params | Return Type | Name and description |
|---|---|---|
|
public Object |
coerceArgument(Object argument)Coerces the given numeric argument to a short value. |
|
public boolean |
isAssignableFrom(Class classToTransformFrom)Determines if the given class can be transformed to short/Short. |
|
public boolean |
isDirectlyAssignable(Object argument)Checks if the given argument is directly assignable without type conversion. |
| Methods inherited from class | Name |
|---|---|
class NumberCachedClass |
coerceArgument, isAssignableFrom |
class CachedClass |
addNewMopMethods, coerceArgument, getCachedClass, getCachedSuperClass, getCallSiteLoader, getConstructors, getDeclaredInterfaces, getFields, getHierarchy, getInterfaces, getMethods, getModifiers, getName, getNewMetaMethods, getSuperClassDistance, getTheClass, getTypeDescription, hashCode, isAssignableFrom, isDirectlyAssignable, isInterface, isPrimitive, isVoid, searchMethods, setNewMopMethods, toString |
Coerces the given numeric argument to a short value.
argument - the argument to coerceshort, or the original argument if not a numberDetermines if the given class can be transformed to short/Short. Accepts byte and short integral types and their boxed variants.
classToTransformFrom - the source class to checktrue if the class can be transformed to short, false otherwiseCopyright © 2003-2026 The Apache Software Foundation. All rights reserved.