public static List<Class<?>> getTypes(final String str) throws IOException {
        List<Class<?>> result = new ArrayList<>();
        byte[] s = str.trim().getBytes();
        if (!(s[0] == '(' && s[str.length() - 1] == ')')) {
            throw new IOException("wrong type (no brackets)");
        }
        for (int i = 1; i < str.length() - 1; ++i) {
            if (s[i] == ' ') {
                continue;
            }

            boolean flag = false;
            for (int j = 0; j < TYPES.length; ++j) {
                if (new String(s, i, Math.min(TYPES[j].length(), str.length() - i)).equals(TYPES[j])) {
                    result.add(CLASSES[j]);
                    i += TYPES[j].length();
                    flag = true;
                    break;
                }
            }

            if (!flag) {
                throw new IOException("Cannot read type! position: " + i);
            }
        }
        return result;
    }