public static Result clone(Result result) { if (result == null) return null; Result clone = create(); clone.setType(ObjectUtil.clone(result.getType())); clone.setName(ObjectUtil.clone(result.getName())); clone.setKey(ObjectUtil.clone(result.getKey())); clone.setConstruct(ObjectUtil.clone(result.getConstruct())); clone.setRequired(ObjectUtil.clone(result.getRequired())); return clone; }
public static void initialize(Result result) { if (result.getRequired() == null) result.setRequired(false); }