CPD Results
The following document contains the results of PMD's CPD 6.46.0.
Duplications
File |
Line |
org/joda/beans/ser/json/JodaBeanJsonWriter.java |
292 |
org/joda/beans/ser/json/JodaBeanSimpleJsonWriter.java |
209 |
output.writeArrayEnd();
}
// write table
private void writeTable(SerIterator itemIterator) throws IOException {
output.writeArrayStart();
while (itemIterator.hasNext()) {
itemIterator.next();
output.writeArrayItemStart();
output.writeArrayStart();
output.writeArrayItemStart();
writeObject(itemIterator.keyType(), itemIterator.key(), null);
output.writeArrayItemStart();
writeObject(itemIterator.columnType(), itemIterator.column(), null);
output.writeArrayItemStart();
writeObject(itemIterator.valueType(), itemIterator.value(), itemIterator);
output.writeArrayEnd();
}
output.writeArrayEnd();
}
// write grid using sparse approach
private void writeGrid(SerIterator itemIterator) throws IOException {
output.writeArrayStart();
output.writeArrayItemStart();
output.writeInt(itemIterator.dimensionSize(0));
output.writeArrayItemStart();
output.writeInt(itemIterator.dimensionSize(1));
while (itemIterator.hasNext()) {
itemIterator.next();
output.writeArrayItemStart();
output.writeArrayStart();
output.writeArrayItemStart();
output.writeInt((Integer) itemIterator.key());
output.writeArrayItemStart();
output.writeInt((Integer) itemIterator.column());
output.writeArrayItemStart();
writeObject(itemIterator.valueType(), itemIterator.value(), itemIterator);
output.writeArrayEnd();
}
output.writeArrayEnd();
}
// write counted set
private void writeCounted(final SerIterator itemIterator) throws IOException {
output.writeArrayStart();
while (itemIterator.hasNext()) {
itemIterator.next();
output.writeArrayItemStart();
output.writeArrayStart();
output.writeArrayItemStart();
writeObject(itemIterator.valueType(), itemIterator.value(), itemIterator);
output.writeArrayItemStart();
output.writeInt(itemIterator.count());
output.writeArrayEnd();
}
output.writeArrayEnd();
}
// write collection object
private void writeObject(Class<?> declaredType, Object obj, SerIterator parentIterator) throws IOException {
if (obj == null) {
output.writeNull();
} else if (settings.getConverter().isConvertible(obj.getClass())) {
writeSimple(declaredType, obj);
} else if (obj instanceof Bean) {
writeBean((Bean) obj, declaredType, RootType.NOT_ROOT);
|
File |
Line |
org/joda/beans/ser/json/JodaBeanJsonWriter.java |
230 |
org/joda/beans/ser/json/JodaBeanSimpleJsonWriter.java |
148 |
output.writeObjectEnd();
}
}
// write list/set/array
private void writeArray(SerIterator itemIterator) throws IOException {
output.writeArrayStart();
while (itemIterator.hasNext()) {
itemIterator.next();
output.writeArrayItemStart();
writeObject(itemIterator.valueType(), itemIterator.value(), itemIterator);
}
output.writeArrayEnd();
}
// write map
private void writeMap(SerIterator itemIterator) throws IOException {
// if key type is known and convertible use short key format, else use full bean format
if (settings.getConverter().isConvertible(itemIterator.keyType())) {
writeMapSimple(itemIterator);
} else {
writeMapComplex(itemIterator);
}
}
// write map with simple keys
private void writeMapSimple(SerIterator itemIterator) throws IOException {
StringConverter<Object> keyConverter = settings.getConverter().findConverterNoGenerics(itemIterator.keyType());
output.writeObjectStart();
while (itemIterator.hasNext()) {
itemIterator.next();
Object key = itemIterator.key();
if (key == null) {
throw new IllegalArgumentException("Unable to write map key as it cannot be null");
}
String str = keyConverter.convertToString(itemIterator.key());
if (str == null) {
throw new IllegalArgumentException("Unable to write map key as it cannot be a null string");
}
output.writeObjectKey(str);
writeObject(itemIterator.valueType(), itemIterator.value(), itemIterator);
}
output.writeObjectEnd();
}
// write map with complex keys
private void writeMapComplex(SerIterator itemIterator) throws IOException {
output.writeArrayStart();
|
File |
Line |
org/joda/beans/impl/light/LightMetaBean.java |
418 |
org/joda/beans/impl/reflection/ReflectiveMetaProperty.java |
90 |
}
// finds a method on class or public method on super-type
private static Method findGetMethod(Class<? extends Bean> beanType, String getterName) {
try {
return beanType.getDeclaredMethod(getterName);
} catch (NoSuchMethodException ex) {
try {
return beanType.getMethod(getterName);
} catch (NoSuchMethodException ex2) {
return null;
}
}
}
// finds a method on class or public method on super-type
private static Method findSetMethod(Class<? extends Bean> beanType, String setterName, Class<?> fieldType) {
try {
return beanType.getDeclaredMethod(setterName, fieldType);
} catch (NoSuchMethodException ex) {
Method[] methods = beanType.getMethods();
List<Method> potential = new ArrayList<>();
for (Method method : methods) {
if (method.getName().equals(setterName) && method.getParameterTypes().length == 1) {
potential.add(method);
}
}
if (potential.size() == 1) {
return potential.get(0);
}
for (Method method : potential) {
if (method.getParameterTypes()[0].equals(fieldType)) {
return method;
}
}
return null;
}
}
|
File |
Line |
org/joda/beans/gen/SetterGen.java |
71 |
org/joda/beans/gen/SetterGen.java |
187 |
@Override
boolean isSetterGenerated(PropertyData prop) {
return true;
}
@Override
List<String> generateSetter(String indent, PropertyData prop) {
List<String> list = new ArrayList<>();
list.add("\t/**");
list.add("\t * Sets " + prop.getFirstComment());
for (String comment : prop.getComments()) {
list.add("\t * " + comment);
}
list.add("\t * @param " + prop.getPropertyName() + " the new value of the property" + prop.getNotNullJavadoc());
if (prop.getDeprecatedComment() != null) {
list.add("\t * " + prop.getDeprecatedComment());
}
list.add("\t */");
if (prop.isOverrideSet()) {
list.add("\t@Override");
}
if (prop.isDeprecated()) {
list.add("\t@Deprecated");
}
list.add("\t" + access + "void set" + prop.getUpperName() + "(" + prop.getType() + " " + prop.getPropertyName() + ") {");
|
File |
Line |
org/joda/beans/ser/GuavaSerIteratorFactory.java |
388 |
org/joda/beans/ser/GuavaSerIteratorFactory.java |
436 |
final ListMultimap<Object, Object> map = ArrayListMultimap.create();
return new SerIterable() {
@Override
public SerIterator iterator() {
return multimap(map, Object.class, keyType, valueType, valueTypeTypes);
}
@Override
public void add(Object key, Object column, Object value, int count) {
if (key == null) {
throw new IllegalArgumentException("Missing key");
}
if (count != 1) {
throw new IllegalArgumentException("Unexpected count");
}
map.put(key, value);
}
@Override
public Object build() {
return map;
}
@Override
public SerCategory category() {
return SerCategory.MAP;
}
@Override
public Class<?> keyType() {
return keyType;
}
@Override
public Class<?> valueType() {
return valueType;
}
@Override
public List<Class<?>> valueTypeTypes() {
return valueTypeTypes;
}
};
}
|
File |
Line |
org/joda/beans/ser/SerIteratorFactory.java |
769 |
org/joda/beans/ser/SerIteratorFactory.java |
836 |
return new SerIterator() {
private int index = -1;
@Override
public String metaTypeName() {
return metaTypeNameBase(valueType);
}
private String metaTypeNameBase(Class<?> arrayType) {
if (arrayType.isArray()) {
return metaTypeNameBase(arrayType.getComponentType()) + "[]";
}
if (arrayType == Object.class) {
return "Object[]";
}
if (arrayType == String.class) {
return "String[]";
}
return arrayType.getName() + "[]";
}
@Override
public boolean metaTypeRequired() {
if (valueType == Object.class) {
return Object[].class.isAssignableFrom(declaredType) == false;
}
if (valueType == String.class) {
return String[].class.isAssignableFrom(declaredType) == false;
}
return true;
}
@Override
public int size() {
return array.length;
|
File |
Line |
org/joda/beans/ser/GuavaSerIteratorFactory.java |
712 |
org/joda/beans/ser/SerIteratorFactory.java |
632 |
return BiMap.class.isAssignableFrom(declaredType) == false;
}
@Override
public SerCategory category() {
return SerCategory.MAP;
}
@Override
public int size() {
return map.size();
}
@Override
public boolean hasNext() {
return it.hasNext();
}
@Override
public void next() {
current = (Entry) it.next();
}
@Override
public Class<?> keyType() {
return keyType;
}
@Override
public Object key() {
return current.getKey();
}
@Override
public Class<?> valueType() {
return valueType;
}
@Override
public List<Class<?>> valueTypeTypes() {
return valueTypeTypes;
}
@Override
public Object value() {
return current.getValue();
}
};
}
/**
* Gets an iterable wrapper for {@code ImmutableList}.
*
* @param valueType the value type, not null
* @param valueTypeTypes the generic parameters of the value type
* @return the iterable, not null
*/
public static final SerIterable immutableList(
|
File |
Line |
org/joda/beans/ser/GuavaSerIteratorFactory.java |
440 |
org/joda/beans/ser/SerIteratorFactory.java |
573 |
return multimap(map, Object.class, keyType, valueType, valueTypeTypes);
}
@Override
public void add(Object key, Object column, Object value, int count) {
if (key == null) {
throw new IllegalArgumentException("Missing key");
}
if (count != 1) {
throw new IllegalArgumentException("Unexpected count");
}
map.put(key, value);
}
@Override
public Object build() {
return map;
}
@Override
public SerCategory category() {
return SerCategory.MAP;
}
@Override
public Class<?> keyType() {
return keyType;
}
@Override
public Class<?> valueType() {
return valueType;
}
@Override
public List<Class<?>> valueTypeTypes() {
return valueTypeTypes;
}
};
}
/**
* Gets an iterator wrapper for {@code Multimap}.
*
* @param map the collection, not null
* @param declaredType the declared type, not null
* @param keyType the key type, not null
* @param valueType the value type, not null
* @param valueTypeTypes the generic parameters of the value type
* @return the iterator, not null
*/
@SuppressWarnings("rawtypes")
public static final SerIterator multimap(
|
File |
Line |
org/joda/beans/ser/GuavaSerIteratorFactory.java |
392 |
org/joda/beans/ser/SerIteratorFactory.java |
573 |
return multimap(map, Object.class, keyType, valueType, valueTypeTypes);
}
@Override
public void add(Object key, Object column, Object value, int count) {
if (key == null) {
throw new IllegalArgumentException("Missing key");
}
if (count != 1) {
throw new IllegalArgumentException("Unexpected count");
}
map.put(key, value);
}
@Override
public Object build() {
return map;
}
@Override
public SerCategory category() {
return SerCategory.MAP;
}
@Override
public Class<?> keyType() {
return keyType;
}
@Override
public Class<?> valueType() {
return valueType;
}
@Override
public List<Class<?>> valueTypeTypes() {
return valueTypeTypes;
}
};
}
|
File |
Line |
org/joda/beans/MetaBean.java |
214 |
org/joda/beans/MetaProperty.java |
131 |
@SuppressWarnings("unchecked")
public default <A extends Annotation> A annotation(Class<A> annotationClass) {
List<Annotation> annotations = annotations();
for (Annotation annotation : annotations) {
if (annotationClass.isInstance(annotation)) {
return (A) annotation;
}
}
throw new NoSuchElementException("Unknown annotation: " + annotationClass.getName());
}
/**
* Finds an optional annotation from the property.
* <p>
* The annotations are queried from the property.
* This is typically accomplished by querying the annotations of the underlying
* instance variable however any strategy is permitted.
*
* @param <A> the annotation type
* @param annotationClass the annotation class to find, not null
* @return the annotation, empty if not found
* @since 2.11.0
*/
@SuppressWarnings("unchecked")
public default <A extends Annotation> Optional<A> annotationOpt(Class<A> annotationClass) {
List<Annotation> annotations = annotations();
for (Annotation annotation : annotations) {
if (annotationClass.isInstance(annotation)) {
return Optional.of((A) annotation);
}
}
return Optional.empty();
}
|
File |
Line |
org/joda/beans/ser/json/JodaBeanJsonWriter.java |
184 |
org/joda/beans/ser/json/JodaBeanSimpleJsonWriter.java |
110 |
for (MetaProperty<?> prop : bean.metaBean().metaPropertyIterable()) {
if (prop.style().isSerializable() || (prop.style().isDerived() && settings.isIncludeDerived())) {
Object value = SerOptional.extractValue(prop, bean);
if (value != null) {
output.writeObjectKey(prop.name());
Class<?> propType = SerOptional.extractType(prop, bean.getClass());
if (value instanceof Bean) {
if (settings.getConverter().isConvertible(value.getClass())) {
writeSimple(propType, value);
} else {
writeBean((Bean) value, propType, RootType.NOT_ROOT);
|
File |
Line |
org/joda/beans/ser/GuavaSerIteratorFactory.java |
870 |
org/joda/beans/ser/GuavaSerIteratorFactory.java |
912 |
static SerIterable immutableMap(
final Class<?> keyType, final Class<?> valueType,
final List<Class<?>> valueTypeTypes) {
final Map<Object, Object> map = new LinkedHashMap<>();
return new SerIterable() {
@Override
public SerIterator iterator() {
return map(map, Object.class, keyType, valueType, valueTypeTypes);
}
@Override
public void add(Object key, Object column, Object value, int count) {
if (key == null) {
throw new IllegalArgumentException("Missing key");
}
if (count != 1) {
throw new IllegalArgumentException("Unexpected count");
}
map.put(key, value);
}
@Override
public Object build() {
return ImmutableMap.copyOf(map);
|
File |
Line |
org/joda/beans/gen/GetterGen.java |
170 |
org/joda/beans/gen/GetterGen.java |
217 |
static final GetterGen PUBLIC = new Optional8GetterGen();
@Override
List<String> generateGetter(PropertyData prop) {
List<String> list = new ArrayList<>();
list.add("\t/**");
list.add("\t * Gets " + prop.getFirstComment());
for (String comment : prop.getComments()) {
list.add("\t * " + comment);
}
list.add("\t * @return the optional value of the property, not null");
if (prop.getDeprecatedComment() != null) {
list.add("\t * " + prop.getDeprecatedComment());
}
list.add("\t */");
if (prop.isOverrideGet()) {
list.add("\t@Override");
}
if (prop.isDeprecated()) {
list.add("\t@Deprecated");
}
|
File |
Line |
org/joda/beans/ser/SerIteratorFactory.java |
368 |
org/joda/beans/ser/SerIteratorFactory.java |
435 |
return new SerIterable() {
@Override
public SerIterator iterator() {
return collection(coll, Object.class, valueType, valueTypeTypes);
}
@Override
public void add(Object key, Object column, Object value, int count) {
if (key != null) {
throw new IllegalArgumentException("Unexpected key");
}
for (int i = 0; i < count; i++) {
coll.add(value);
}
}
@Override
public Object build() {
return coll;
}
@Override
public Class<?> valueType() {
return valueType;
}
@Override
public List<Class<?>> valueTypeTypes() {
return valueTypeTypes;
}
};
}
|
File |
Line |
org/joda/beans/impl/direct/MinimalMetaBean.java |
240 |
org/joda/beans/impl/light/LightMetaBean.java |
262 |
this.aliasMap = new HashMap<>();
}
// determine the field names by reflection
// this is fundamentally broken as Java does not guarantee that the field names
// are returned in the order defined in the source file
private static String[] fieldNames(Class<?> beanType) {
Field[] fields = Stream.of(beanType.getDeclaredFields())
.filter(f -> !Modifier.isStatic(f.getModifiers()) && f.getAnnotation(PropertyDefinition.class) != null)
.toArray(Field[]::new);
List<String> fieldNames = new ArrayList<>();
for (int i = 0; i < fields.length; i++) {
fieldNames.add(fields[i].getName());
}
return fieldNames.toArray(new String[fieldNames.size()]);
}
|
File |
Line |
org/joda/beans/impl/light/LightMetaBean.java |
161 |
org/joda/beans/impl/light/LightMetaBean.java |
380 |
}
// derived
Method[] methods = beanType.getDeclaredMethods();
for (Method method : methods) {
if (!Modifier.isStatic(method.getModifiers()) &&
method.getAnnotation(DerivedProperty.class) != null &&
method.getName().startsWith("get") &&
method.getName().length() > 3 &&
Character.isUpperCase(method.getName().charAt(3)) &&
method.getParameterTypes().length == 0) {
String methodName = method.getName();
String propertyName = Character.toLowerCase(methodName.charAt(3)) + methodName.substring(4);
|
File |
Line |
org/joda/beans/ser/GuavaSerIteratorFactory.java |
760 |
org/joda/beans/ser/SerIteratorFactory.java |
365 |
public static final SerIterable immutableList(
final Class<?> valueType, final List<Class<?>> valueTypeTypes) {
final List<Object> coll = new ArrayList<>();
return new SerIterable() {
@Override
public SerIterator iterator() {
return collection(coll, Object.class, valueType, valueTypeTypes);
}
@Override
public void add(Object key, Object column, Object value, int count) {
if (key != null) {
throw new IllegalArgumentException("Unexpected key");
}
for (int i = 0; i < count; i++) {
coll.add(value);
}
}
@Override
public Object build() {
return ImmutableList.copyOf(coll);
|
File |
Line |
org/joda/beans/ser/GuavaSerIteratorFactory.java |
799 |
org/joda/beans/ser/GuavaSerIteratorFactory.java |
838 |
public static final SerIterable immutableSortedSet(
final Class<?> valueType, final List<Class<?>> valueTypeTypes) {
final Set<Object> coll = new LinkedHashSet<>();
return new SerIterable() {
@Override
public SerIterator iterator() {
return collection(coll, Object.class, valueType, valueTypeTypes);
}
@Override
public void add(Object key, Object column, Object value, int count) {
if (key != null) {
throw new IllegalArgumentException("Unexpected key");
}
for (int i = 0; i < count; i++) {
coll.add(value);
}
}
@Override
public Object build() {
return ImmutableSortedSet.copyOf(coll);
|
File |
Line |
org/joda/beans/impl/direct/DirectFieldsBeanBuilder.java |
36 |
org/joda/beans/impl/direct/DirectPrivateBeanBuilder.java |
36 |
protected DirectFieldsBeanBuilder() {
}
//-----------------------------------------------------------------------
@Override
public Object get(String propertyName) {
throw new UnsupportedOperationException();
}
@Override
@SuppressWarnings("unchecked")
public <P> P get(MetaProperty<P> metaProperty) {
return (P) get(metaProperty.name());
}
//-----------------------------------------------------------------------
@Override
public BeanBuilder<T> set(MetaProperty<?> metaProperty, Object value) {
try {
set(metaProperty.name(), value);
return this;
} catch (RuntimeException ex) {
if (value == JodaBeanTests.TEST_COVERAGE_STRING) {
return this;
}
throw ex;
}
}
//-----------------------------------------------------------------------
/**
* Returns a string that summarises the builder.
*
* @return a summary string, not null
*/
@Override
public String toString() {
return "BeanBuilder";
}
}
|
File |
Line |
org/joda/beans/impl/light/LightMetaBean.java |
118 |
org/joda/beans/impl/light/LightMetaBean.java |
349 |
} else {
String getterName = "get" + name.substring(0, 1).toUpperCase(Locale.ENGLISH) + name.substring(1);
Method getMethod = null;
if (field.getType() == boolean.class) {
getMethod = findGetMethod(beanType,
"is" + name.substring(0, 1).toUpperCase(Locale.ENGLISH) + name.substring(1));
}
if (getMethod == null) {
getMethod = findGetMethod(beanType, getterName);
if (getMethod == null) {
throw new IllegalArgumentException(
"Unable to find property getter: " + beanType.getSimpleName() + "." + getterName + "()");
}
}
|
File |
Line |
org/joda/beans/ser/bin/AbstractBinWriter.java |
95 |
org/joda/beans/ser/json/JodaBeanJsonWriter.java |
188 |
output.writeString(prop.name());
Class<?> propType = SerOptional.extractType(prop, bean.getClass());
if (value instanceof Bean) {
if (settings.getConverter().isConvertible(value.getClass())) {
writeSimple(propType, value);
} else {
writeBean((Bean) value, propType, RootType.NOT_ROOT);
}
} else {
SerIterator itemIterator = settings.getIteratorFactory().create(value, prop, bean.getClass());
if (itemIterator != null) {
writeElements(itemIterator);
} else {
writeSimple(propType, value);
}
}
}
}
|
File |
Line |
org/joda/beans/impl/direct/MinimalMetaBean.java |
298 |
org/joda/beans/impl/light/LightMetaBean.java |
591 |
return builderSupplier.get();
}
@Override
public Class<T> beanType() {
return beanType;
}
@Override
@SuppressWarnings("unchecked")
public <R> MetaProperty<R> metaProperty(String propertyName) {
MetaProperty<?> mp = metaPropertyMap().get(aliasMap.getOrDefault(propertyName, propertyName));
if (mp == null) {
throw new NoSuchElementException("Unknown property: " + propertyName);
}
return (MetaProperty<R>) mp;
}
@Override
public Map<String, MetaProperty<?>> metaPropertyMap() {
return metaPropertyMap;
}
//-----------------------------------------------------------------------
@Override
public boolean equals(Object obj) {
if (obj instanceof MinimalMetaBean) {
|
File |
Line |
org/joda/beans/ser/json/JodaBeanJsonWriter.java |
358 |
org/joda/beans/ser/json/JodaBeanSimpleJsonWriter.java |
275 |
writeBean((Bean) obj, declaredType, RootType.NOT_ROOT);
} else if (parentIterator != null) {
SerIterator childIterator = settings.getIteratorFactory().createChild(obj, parentIterator);
if (childIterator != null) {
writeElements(childIterator);
} else {
writeSimple(declaredType, obj);
}
} else {
writeSimple(declaredType, obj);
}
}
//-----------------------------------------------------------------------
// write simple type
private void writeSimple(Class<?> declaredType, Object value) throws IOException {
// simple types have no need to write a type object
Class<?> realType = value.getClass();
if (realType == Integer.class) {
output.writeInt(((Integer) value).intValue());
|
File |
Line |
org/joda/beans/ser/bin/AbstractBinWriter.java |
209 |
org/joda/beans/ser/json/JodaBeanJsonWriter.java |
354 |
output.writeNil();
} else if (settings.getConverter().isConvertible(obj.getClass())) {
writeSimple(declaredType, obj);
} else if (obj instanceof Bean) {
writeBean((Bean) obj, declaredType, RootType.NOT_ROOT);
} else if (parentIterator != null) {
SerIterator childIterator = settings.getIteratorFactory().createChild(obj, parentIterator);
if (childIterator != null) {
writeElements(childIterator);
} else {
writeSimple(declaredType, obj);
}
} else {
writeSimple(declaredType, obj);
}
}
|
File |
Line |
org/joda/beans/gen/BeanCodeGen.java |
301 |
org/joda/beans/gen/BeanCodeGen.java |
324 |
gen.process();
if (contentDiffers(content, original)) {
if (write) {
if (verbosity >= 2) {
System.out.println(" [writing]");
} else if (verbosity == 1) {
System.out.println(file + " [writing]");
}
writeFile(file, content);
} else {
if (verbosity >= 2) {
System.out.println(" [changed not written]");
} else if (verbosity == 1) {
System.out.println(file + " [changed not written]");
}
}
return file;
} else {
if (verbosity >= 2) {
|
File |
Line |
org/joda/beans/impl/direct/MinimalMetaBean.java |
227 |
org/joda/beans/impl/light/LightMetaBean.java |
384 |
Modifier.isPublic(method.getModifiers()) &&
method.getAnnotation(DerivedProperty.class) != null &&
method.getName().startsWith("get") &&
method.getName().length() > 3 &&
Character.isUpperCase(method.getName().charAt(3)) &&
method.getParameterTypes().length == 0) {
String methodName = method.getName();
String propertyName = Character.toLowerCase(methodName.charAt(3)) + methodName.substring(4);
MetaProperty<Object> mp = new MinimalMetaProperty<>(this, method, propertyName);
|
File |
Line |
org/joda/beans/impl/light/ImmutableLightMetaProperty.java |
94 |
org/joda/beans/impl/light/ImmutableLightMetaProperty.java |
136 |
Field field,
final Method method,
final String propertyName,
int constructorIndex) {
PropertyGetter getter = new PropertyGetter() {
@Override
public Object get(Bean bean) {
try {
return method.invoke(bean);
} catch (IllegalArgumentException | IllegalAccessException ex) {
throw new UnsupportedOperationException("Property cannot be read: " + propertyName, ex);
} catch (InvocationTargetException ex) {
if (ex.getCause() instanceof RuntimeException) {
throw (RuntimeException) ex.getCause();
}
throw new RuntimeException(ex);
}
}
};
return new ImmutableLightMetaProperty<>(
|