All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.thegoate.utils.fill.serialize.model.BuildModel Maven / Gradle / Ivy

package com.thegoate.utils.fill.serialize.model;

import com.thegoate.Goate;
import com.thegoate.utils.fill.serialize.Serializer;

public class BuildModel {

    public Goate model(Class template, Class source, boolean asSourced) throws InstantiationException, IllegalAccessException {
        Goate model = new Serializer<>(template.newInstance(), source).asSourced(asSourced).toGoate();
//        GoateReflection gr = new GoateReflection();
//        Goate model = new Goate();
//        Map fields = gr.findFields(template);
//        for (Map.Entry field : fields.entrySet()) {
//            GoateSource gs = findGoateSource(field.getValue(), source);
//            if (gs != null) {
//                if (!gs.skipInModel() || !asSourced) {
//                    model.put(field.getValue().)
//                }
//            }
//        }
//        return model;
        return model;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy