class JavaAliasConverter {

    public static String toAlias(String javaType) {
        for (Map.Entry<String, JavaAliasType> type : map.entrySet()) {
            if (type.getValue().getTypes().contains(javaType)) {
                return type.getKey();
            }
        }
        throw new IllegalArgumentException("Can not find alias for java type: " + javaType);
    }

}