Пример #1
0
    public static Builder create(EdoVoteRecordContract contract) {
      if (contract == null) {
        throw new IllegalArgumentException("contract was null");
      }
      // TODO if create() is modified to accept required parameters, this will need to be modified
      Builder builder = create();
      builder.setVoteSubRound(contract.getVoteSubRound());
      builder.setAbstainCount(contract.getAbstainCount());
      builder.setEdoVoteRecordId(contract.getEdoVoteRecordId());
      builder.setEdoDossierId(contract.getEdoDossierId());
      builder.setAbsentCount(contract.getAbsentCount());
      builder.setEdoReviewLayerDefinitionId(contract.getEdoReviewLayerDefinitionId());
      builder.setNoCount(contract.getNoCount());
      builder.setVoteRound(contract.getVoteRound());
      builder.setYesCount(contract.getYesCount());
      builder.setAoeCode(contract.getAoeCode());
      builder.setVoteType(contract.getVoteType());
      builder.setVersionNumber(contract.getVersionNumber());
      builder.setObjectId(contract.getObjectId());

      builder.setCreatedAt(contract.getCreatedAt());
      builder.setUpdatedAt(contract.getUpdatedAt());
      builder.setCreatedBy(contract.getCreatedBy());
      return builder;
    }
Пример #2
0
 private EdoVoteRecord(Builder builder) {
   this.voteSubRound = builder.getVoteSubRound();
   this.abstainCount = builder.getAbstainCount();
   this.edoVoteRecordId = builder.getEdoVoteRecordId();
   this.edoDossierId = builder.getEdoDossierId();
   this.absentCount = builder.getAbsentCount();
   this.edoReviewLayerDefinitionId = builder.getEdoReviewLayerDefinitionId();
   this.noCount = builder.getNoCount();
   this.voteRound = builder.getVoteRound();
   this.yesCount = builder.getYesCount();
   this.aoeCode = builder.getAoeCode();
   this.voteType = builder.getVoteType();
   this.versionNumber = builder.getVersionNumber();
   this.objectId = builder.getObjectId();
   this.createdAt = builder.getCreatedAt();
   this.updatedAt = builder.getUpdatedAt();
   this.createdBy = builder.getCreatedBy();
 }