/** * For test purposes only. This isn't quite accurate, because I think two RVVs that have * effectively same exceptions may represent the exceptions differently. This method is testing * for an exact match of exception format. <br> */ @Override public boolean sameAs(RVVException ex) { if (!super.sameAs(ex)) { return false; } RVVExceptionT other = (RVVExceptionT) ex; if (this.received == null) { if (other.received != null && !other.received.isEmpty()) { return false; } } else if (other.received == null || !this.received.equals(other.received)) { return false; } return true; }
/** * For test purposes only. This isn't quite accurate, because I think two RVVs that have * effectively same exceptions may represent the exceptions differently. This method is testing * for an exact match of exception format. */ @Override public boolean sameAs(RVVException ex) { if (ex instanceof RVVExceptionT) { return ((RVVExceptionT) ex).sameAs(this); } if (!super.sameAs(ex)) { return false; } RVVExceptionB other = (RVVExceptionB) ex; if (this.received == null) { if (other.received != null && !other.received.isEmpty()) { return false; } } else if (!this.received.equals(other.received)) return false; return true; }
Iterator<RVVException> it2 = e2.iterator(); while (it1.hasNext() && it2.hasNext()) { if (!it1.next().sameAs(it2.next())) { return false;
protected boolean sameAs(RVVExceptionB ex) { if (!super.sameAs(ex)) { return false; } for (ReceivedVersionsReverseIterator it = receivedVersionsReverseIterator(); it.hasNext();) { if (!ex.contains(it.next())) { return false; } } for (ReceivedVersionsReverseIterator it = ex.receivedVersionsReverseIterator(); it.hasNext();) { if (!contains(it.next())) { return false; } } return true; }