예제 #1
0
  public OlePatronLoanDocuments(Builder builder) {

    this.olePatronLoanItem = new ArrayList<OlePatronLoanDocument>();
    if (!CollectionUtils.isEmpty(builder.getOlePatronLoanDocuments())) {
      for (OlePatronLoanDocument.Builder olePatronLoanDocument :
          builder.getOlePatronLoanDocuments()) {
        this.olePatronLoanItem.add(olePatronLoanDocument.build());
      }
    }
  }
예제 #2
0
    public static Builder create(OlePatronLoanDocumentsContract contract) {

      if (contract == null) {
        throw new IllegalArgumentException("contract was null");
      }
      Builder builder = create();

      builder.olePatronLoanDocuments = new ArrayList<OlePatronLoanDocument.Builder>();
      if (!CollectionUtils.isEmpty(contract.getOlePatronLoanDocuments())) {
        for (OlePatronLoanDocumentContract olePatronLoanDocumentContract :
            contract.getOlePatronLoanDocuments()) {
          builder.olePatronLoanDocuments.add(
              OlePatronLoanDocument.Builder.create(olePatronLoanDocumentContract));
        }
      }

      builder.setVersionNumber(contract.getVersionNumber());

      // builder.setId(contract.getId());

      return builder;
    }
예제 #3
0
    public static Builder create(OleDeliverRequestContract contract) {
      if (contract == null) {
        throw new IllegalArgumentException("contract was null");
      }
      Builder builder = create();
      if (contract.getTitle() != null) {
        builder.setTitle(contract.getTitle());
      }
      if (contract.getAuthor() != null) {
        builder.setAuthor(contract.getAuthor());
      }
      if (contract.getCallNumber() != null) {
        builder.setCallNumber(contract.getCallNumber());
      }
      if (contract.getCopyNumber() != null) {
        builder.setCopyNumber(contract.getCopyNumber());
      }
      if (contract.getItemStatus() != null) {
        builder.setItemStatus(contract.getItemStatus());
      }
      if (contract.getItemType() != null) {
        builder.setItemType(contract.getItemType());
      }
      if (contract.getShelvingLocation() != null) {
        builder.setShelvingLocation(contract.getShelvingLocation());
      }
      if (contract.getVolumeNumber() != null) {
        builder.setVolumeNumber(contract.getVolumeNumber());
      }
      if (contract.getItemId() != null) {
        builder.setItemId(contract.getItemId());
      }
      if (contract.getRequestId() != null) {
        builder.setRequestId(contract.getRequestId());
      }
      if (contract.getRequestId() != null) {
        builder.setRequestId(contract.getRequestId());
      }
      if (contract.getBorrowerQueuePosition() != null) {
        builder.setBorrowerQueuePosition(contract.getBorrowerQueuePosition());
      }
      if (contract.getCreateDate() != null) {
        builder.setCreateDate(contract.getCreateDate());
      }
      if (contract.getOleDeliverRequestType() != null) {
        builder.setOleDeliverRequestType(
            OleDeliverRequestTypeDefinition.Builder.create(contract.getOleDeliverRequestType()));
      }

      builder.setId(contract.getId());
      return builder;
    }
예제 #4
0
 private OleDeliverRequestDefinition(Builder builder) {
   this.title = builder.getTitle();
   this.author = builder.getAuthor();
   this.callNumber = builder.getCallNumber();
   this.copyNumber = builder.getCopyNumber();
   this.itemType = builder.getItemType();
   this.itemStatus = builder.getItemStatus();
   this.shelvingLocation = builder.getShelvingLocation();
   this.volumeNumber = builder.getVolumeNumber();
   this.patronName = builder.getPatronName();
   this.itemId = builder.getItemId();
   this.requestId = builder.getRequestId();
   this.borrowerQueuePosition = builder.getBorrowerQueuePosition();
   this.createDate = builder.getCreateDate();
   this.oleDeliverRequestType = builder.getOleDeliverRequestType().build();
   this.versionNumber = builder.getVersionNumber();
   // this.objectId = builder.getObjectId();
 }