private static final Set createUnsafeMethodsSet() { try { Properties props = ClassUtil.loadProperties(BeansWrapper.class, UNSAFE_METHODS_PROPERTIES); Set set = new HashSet(props.size() * 4 / 3, 1f); Map primClasses = createPrimitiveClassesMap(); for (Object key : props.keySet()) { try { set.add(parseMethodSpec((String) key, primClasses)); } catch (ClassNotFoundException e) { if (ClassIntrospector.DEVELOPMENT_MODE) { throw e; } } catch (NoSuchMethodException e) { if (ClassIntrospector.DEVELOPMENT_MODE) { throw e; } } } return set; } catch (Exception e) { throw new RuntimeException("Could not load unsafe method set", e); } }
private static final Set createUnsafeMethodsSet() { try { Properties props = ClassUtil.loadProperties(BeansWrapper.class, UNSAFE_METHODS_PROPERTIES); Set set = new HashSet(props.size() * 4 / 3, 1f); Map primClasses = createPrimitiveClassesMap(); for (Object key : props.keySet()) { try { set.add(parseMethodSpec((String) key, primClasses)); } catch (ClassNotFoundException e) { if (ClassIntrospector.DEVELOPMENT_MODE) { throw e; } } catch (NoSuchMethodException e) { if (ClassIntrospector.DEVELOPMENT_MODE) { throw e; } } } return set; } catch (Exception e) { throw new RuntimeException("Could not load unsafe method set", e); } }
private static final Set createUnsafeMethodsSet() { try { Properties props = ClassUtil.loadProperties(BeansWrapper.class, UNSAFE_METHODS_PROPERTIES); Set set = new HashSet(props.size() * 4 / 3, 1f); Map primClasses = createPrimitiveClassesMap(); for (Object key : props.keySet()) { try { set.add(parseMethodSpec((String) key, primClasses)); } catch (ClassNotFoundException e) { if (ClassIntrospector.DEVELOPMENT_MODE) { throw e; } } catch (NoSuchMethodException e) { if (ClassIntrospector.DEVELOPMENT_MODE) { throw e; } } } return set; } catch (Exception e) { throw new RuntimeException("Could not load unsafe method set", e); } }