public String toString(final Address[] order, boolean print_highest_received) { StringBuilder sb=new StringBuilder(); boolean first=true; if(capacity() == 0) return "[]"; int count=0, capacity=capacity(); for(Address key: order) { long[] tmp_seqnos=key != null? get(key) : null; if(key == null || tmp_seqnos == null) continue; if(!first) sb.append(", "); else first=false; sb.append(key).append(": ").append('[').append(tmp_seqnos[0]); if(print_highest_received) sb.append(" (").append(tmp_seqnos[1]).append(")"); sb.append("]"); if(Util.MAX_LIST_PRINT_SIZE > 0 && ++count >= Util.MAX_LIST_PRINT_SIZE) { if(capacity > count) sb.append(", ..."); break; } } return sb.toString(); }
public String toString(final Address[] order, boolean print_highest_received) { StringBuilder sb=new StringBuilder(); boolean first=true; if(capacity() == 0) return "[]"; int count=0, capacity=capacity(); for(Address key: order) { long[] tmp_seqnos=key != null? get(key) : null; if(key == null || tmp_seqnos == null) continue; if(!first) sb.append(", "); else first=false; sb.append(key).append(": ").append('[').append(tmp_seqnos[0]); if(print_highest_received) sb.append(" (").append(tmp_seqnos[1]).append(")"); sb.append("]"); if(Util.MAX_LIST_PRINT_SIZE > 0 && ++count >= Util.MAX_LIST_PRINT_SIZE) { if(capacity > count) sb.append(", ..."); break; } } return sb.toString(); }
public String toString(final Address[] order, boolean print_highest_received) { StringBuilder sb=new StringBuilder(); boolean first=true; if(capacity() == 0) return "[]"; int count=0, capacity=capacity(); for(Address key: order) { long[] tmp_seqnos=key != null? get(key) : null; if(key == null || tmp_seqnos == null) continue; if(!first) sb.append(", "); else first=false; sb.append(key).append(": ").append('[').append(tmp_seqnos[0]); if(print_highest_received) sb.append(" (").append(tmp_seqnos[1]).append(")"); sb.append("]"); if(Util.MAX_LIST_PRINT_SIZE > 0 && ++count >= Util.MAX_LIST_PRINT_SIZE) { if(capacity > count) sb.append(", ..."); break; } } return sb.toString(); }
/** * Returns true if all senders of the current digest have their seqnos >= the ones from other */ protected static boolean isGreaterThanOrEqual(Digest first, Digest other) { if(other == null) return true; for(Digest.Entry entry: first) { Address sender=entry.getMember(); long[] their_entry=other.get(sender); if(their_entry == null) continue; long my_highest=entry.getHighest(); long their_highest=Math.max(their_entry[0],their_entry[1]); if(my_highest < their_highest) return false; } return true; }
/** * Returns true if all senders of the current digest have their seqnos >= the ones from other */ protected static boolean isGreaterThanOrEqual(Digest first, Digest other) { if(other == null) return true; for(Digest.Entry entry: first) { Address sender=entry.getMember(); long[] their_entry=other.get(sender); if(their_entry == null) continue; long my_highest=entry.getHighest(); long their_highest=Math.max(their_entry[0],their_entry[1]); if(my_highest < their_highest) return false; } return true; }
/** * Returns true if all senders of the current digest have their seqnos >= the ones from other */ protected static boolean isGreaterThanOrEqual(Digest first, Digest other) { if(other == null) return true; for(Digest.Entry entry: first) { Address sender=entry.getMember(); long[] their_entry=other.get(sender); if(their_entry == null) continue; long my_highest=entry.getHighest(); long their_highest=Math.max(their_entry[0],their_entry[1]); if(my_highest < their_highest) return false; } return true; }
/** * Returns true if all senders of the current digest have their seqnos >= the ones from other */ protected static boolean isGreaterThanOrEqual(Digest first, Digest other) { if(other == null) return true; for(Digest.Entry entry: first) { Address sender=entry.getMember(); long[] their_entry=other.get(sender); if(their_entry == null) continue; long my_highest=entry.getHighest(); long their_highest=Math.max(their_entry[0],their_entry[1]); if(my_highest < their_highest) return false; } return true; }
/** * Returns true if all senders of the current digest have their seqnos >= the ones from other */ protected static boolean isGreaterThanOrEqual(Digest first, Digest other) { if(other == null) return true; for(Digest.Entry entry: first) { Address sender=entry.getMember(); long[] their_entry=other.get(sender); if(their_entry == null) continue; long my_highest=entry.getHighest(); long their_highest=Math.max(their_entry[0],their_entry[1]); if(my_highest < their_highest) return false; } return true; }
/** * Returns true if all senders of the current digest have their seqnos >= the ones from other */ protected static boolean isGreaterThanOrEqual(Digest first, Digest other) { if(other == null) return true; for(Digest.Entry entry: first) { Address sender=entry.getMember(); long[] their_entry=other.get(sender); if(their_entry == null) continue; long my_highest=entry.getHighest(); long their_highest=Math.max(their_entry[0],their_entry[1]); if(my_highest < their_highest) return false; } return true; }
long[] my_entry=my_digest.get(member); if(my_entry == null) continue;
long[] my_entry=my_digest.get(member); if(my_entry == null) continue;
long[] my_entry=my_digest.get(member); if(my_entry == null) continue;
long[] my_entry=my_digest.get(member); if(my_entry == null) continue;
long[] my_entry=my_digest.get(member); if(my_entry == null) continue;
long[] my_entry=my_digest.get(member); if(my_entry == null) continue;