Returns the Class object of arrays with componentType.
(Class<?> componentType)
| 545 | |
| 546 | |
| 547 | static Class<?> getArrayClass(Class<?> componentType) { |
| 548 | // TODO(user): This is not the most efficient way to handle generic |
| 549 | // arrays, but is there another way to extract the array class in a |
| 550 | // non-hacky way (i.e. using String value class names- "[L...")? |
| 551 | return Array.newInstance(componentType, 0).getClass(); |
| 552 | } |
| 553 | |
| 554 | // TODO(benyu): Once we are on Java 8, delete this abstraction |
| 555 |
no test coverage detected