コード例 #1
0
 private boolean FindAcceptedPaymentType(
     AcceptedPaymentType acceptedPaymentType, List<AcceptedPaymentType> acceptedPaymentTypes) {
   for (AcceptedPaymentType newAcceptedPaymentType : acceptedPaymentTypes) {
     if ((newAcceptedPaymentType.getTransactionTypeEntity().getTransactionId().shortValue()
             == acceptedPaymentType.getTransactionTypeEntity().getTransactionId().shortValue())
         && (newAcceptedPaymentType.getPaymentTypeEntity().getId().shortValue())
             == acceptedPaymentType.getPaymentTypeEntity().getId().shortValue()) {
       return true;
     }
   }
   return false;
 }
コード例 #2
0
 private boolean IsDeleted(AcceptedPaymentType a, List<AcceptedPaymentType> list) {
   if ((list == null) || (list.size() == 0)) {
     return true;
   }
   for (AcceptedPaymentType type : list) {
     if ((type.getTransactionTypeEntity().getTransactionId().shortValue()
             == a.getTransactionTypeEntity().getTransactionId().shortValue())
         && (type.getPaymentTypeEntity().getId().shortValue()
             == a.getPaymentTypeEntity().getId().shortValue())) {
       return false;
     }
   }
   return true;
 }