com.badlogic.gdx.utils.reflect
Class ArrayReflection

java.lang.Object
  extended by com.badlogic.gdx.utils.reflect.ArrayReflection

public final class ArrayReflection
extends Object

Utilities for Array reflection.

Author:
nexsoftware

Constructor Summary
ArrayReflection()
           
 
Method Summary
static Object get(Object array, int index)
          Returns the value of the indexed component in the supplied array.
static int getLength(Object array)
          Returns the length of the supplied array.
static Object newInstance(Class c, int size)
          Creates a new array with the specified component type and length.
static void set(Object array, int index, Object value)
          Sets the value of the indexed component in the supplied array to the supplied value.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ArrayReflection

public ArrayReflection()
Method Detail

newInstance

public static Object newInstance(Class c,
                                 int size)
Creates a new array with the specified component type and length.


getLength

public static int getLength(Object array)
Returns the length of the supplied array.


get

public static Object get(Object array,
                         int index)
Returns the value of the indexed component in the supplied array.


set

public static void set(Object array,
                       int index,
                       Object value)
Sets the value of the indexed component in the supplied array to the supplied value.



Copyright © 2013. All Rights Reserved.