net.ibizsys.model.util.merger.eai.PSSysEAISchemeMerger Maven / Gradle / Ivy
package net.ibizsys.model.util.merger.eai;
import com.fasterxml.jackson.databind.node.ObjectNode;
import net.ibizsys.model.util.merger.IPSModelListMerger;
import net.ibizsys.model.util.merger.IPSModelMergeContext;
import net.ibizsys.model.util.merger.PSModelMergerFactory;
import static net.ibizsys.model.eai.PSSysEAISchemeImpl.*;
public class PSSysEAISchemeMerger extends net.ibizsys.model.util.merger.PSModelMergerBase{
@Override
protected boolean isEnableMergeChild(IPSModelMergeContext iPSModelMergeContext, String strFieldName) {
Boolean ret = iPSModelMergeContext.isEnableMergeChild(net.ibizsys.model.eai.PSSysEAISchemeImpl.class, strFieldName);
return (ret != null)?ret:super.isEnableMergeChild(iPSModelMergeContext, strFieldName);
}
@Override
protected void onMerge(IPSModelMergeContext iPSModelMergeContext, ObjectNode objectNode, ObjectNode mergeObjectNode) throws Exception {
if(isEnableMergeChild(iPSModelMergeContext, ATTR_GETALLPSSYSEAIDES)){
IPSModelListMerger iPSModelListMerger = iPSModelMergeContext.getPSModelListMerger(net.ibizsys.model.eai.IPSSysEAIDE.class, true);
if(iPSModelListMerger != null){
iPSModelListMerger.merge(iPSModelMergeContext, objectNode, mergeObjectNode, ATTR_GETALLPSSYSEAIDES);
}
}
if(isEnableMergeChild(iPSModelMergeContext, ATTR_GETALLPSSYSEAIDATATYPES)){
IPSModelListMerger iPSModelListMerger = iPSModelMergeContext.getPSModelListMerger(net.ibizsys.model.eai.IPSSysEAIDataType.class, true);
if(iPSModelListMerger != null){
iPSModelListMerger.merge(iPSModelMergeContext, objectNode, mergeObjectNode, ATTR_GETALLPSSYSEAIDATATYPES);
}
}
if(isEnableMergeChild(iPSModelMergeContext, ATTR_GETALLPSSYSEAIELEMENTS)){
IPSModelListMerger iPSModelListMerger = iPSModelMergeContext.getPSModelListMerger(net.ibizsys.model.eai.IPSSysEAIElement.class, true);
if(iPSModelListMerger != null){
iPSModelListMerger.merge(iPSModelMergeContext, objectNode, mergeObjectNode, ATTR_GETALLPSSYSEAIELEMENTS);
}
}
super.onMerge(iPSModelMergeContext, objectNode, mergeObjectNode);
}
}