org.simpleflatmapper.map.setter.ContextualSetterOnGetter Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of sfm-map Show documentation
Show all versions of sfm-map Show documentation
Java library to map flat record - ResultSet, csv - to java object with minimum configuration and low footprint.
package org.simpleflatmapper.map.setter;
import org.simpleflatmapper.converter.Context;
import org.simpleflatmapper.reflect.Getter;
public class ContextualSetterOnGetter implements ContextualSetter {
private final Getter getter;
private final ContextualSetter setter;
public ContextualSetterOnGetter(ContextualSetter setter, Getter getter) {
this.setter = setter;
this.getter = getter;
}
@Override
public void set(T target, P value, Context context) throws Exception {
setter.set(target, getter.get(value), context);
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy