private void putOrFlatten(FieldMap<V> annotations, Reflect<T,V> reflect, Method getter) { if (annotations.flattened()) { flatten((Class<T>)annotations.targetType(), annotations.attributes(), (Reflect<T,T>)reflect); } else { final Bean<T,V> bean = new Bean<T,V>(annotations, reflect, getter); if (put(bean.properties().attributeName(), bean) != null) { throw new DynamoDBMappingException("duplicate attribute name " + bean.properties().attributeName()); } } }
private void putOrFlatten(FieldMap<V> annotations, Reflect<T,V> reflect, Method getter) { if (annotations.flattened()) { flatten((Class<T>)annotations.targetType(), annotations.attributes(), (Reflect<T,T>)reflect); } else { final Bean<T,V> bean = new Bean<T,V>(annotations, reflect, getter); if (put(bean.properties().attributeName(), bean) != null) { throw new DynamoDBMappingException("duplicate attribute name " + bean.properties().attributeName()); } } }