MCPcopy Index your code
hub / github.com/apache/tomcat / toTypeArray

Method toTypeArray

java/org/apache/el/util/ReflectionUtil.java:107–116  ·  view source on GitHub ↗

Converts an array of Class names to Class types. @param s The array of class names @return An array of Class instance where the element at index i in the result is an instance of the class with the name at index i in the input @throws ClassNotFoundException If a class of a given name

(String[] s)

Source from the content-addressed store, hash-verified

105 * @throws ClassNotFoundException If a class of a given name cannot be found
106 */
107 public static Class<?>[] toTypeArray(String[] s) throws ClassNotFoundException {
108 if (s == null) {
109 return null;
110 }
111 Class<?>[] c = new Class[s.length];
112 for (int i = 0; i < s.length; i++) {
113 c[i] = forName(s[i]);
114 }
115 return c;
116 }
117
118 /**
119 * Converts an array of Class types to Class names.

Callers 3

readExternalMethod · 0.95
readExternalMethod · 0.95
getMethodMethod · 0.95

Calls 1

forNameMethod · 0.95

Tested by

no test coverage detected