diff --git a/core/java/src/net/i2p/data/LeaseSet.java b/core/java/src/net/i2p/data/LeaseSet.java index a917f6ac0536e8656c8f5b1ffeded5e899c20c6b..061091c61fa94d5132e5519c6da8a48450070f8d 100644 --- a/core/java/src/net/i2p/data/LeaseSet.java +++ b/core/java/src/net/i2p/data/LeaseSet.java @@ -66,6 +66,7 @@ public class LeaseSet extends DataStructureImpl { private volatile Hash _currentRoutingKey; private volatile byte[] _routingKeyGenMod; private boolean _receivedAsPublished; + private boolean _receivedAsReply; // Store these since isCurrent() and getEarliestLeaseDate() are called frequently private long _firstExpiration; private long _lastExpiration; @@ -119,11 +120,20 @@ public class LeaseSet extends DataStructureImpl { /** * If true, we received this LeaseSet by a remote peer publishing it to * us, rather than by searching for it ourselves or locally creating it. - * + * Default false. */ public boolean getReceivedAsPublished() { return _receivedAsPublished; } + /** Default false */ public void setReceivedAsPublished(boolean received) { _receivedAsPublished = received; } + /** + * If true, we received this LeaseSet by searching for it + * Default false. + */ + public boolean getReceivedAsReply() { return _receivedAsReply; } + /** set to true */ + public void setReceivedAsReply() { _receivedAsReply = true; } + public void addLease(Lease lease) { if (lease == null) throw new IllegalArgumentException("erm, null lease"); if (lease.getGateway() == null) throw new IllegalArgumentException("erm, lease has no gateway");