blob: f73c92b23daba475a383f2f4e9a13e7e9bf420b0 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
package org.openecomp.sdc.toscaparser.utils;
public final class PythonUtils {
private PythonUtils() {
// No instances allowed
}
public static Object cast(Object object, String pythonTypeName) {
PythonType pythonType = PythonType.fromName(pythonTypeName);
return pythonType.getJavaClass().cast(object);
}
}
|