X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=blobdiff_plain;ds=inline;f=src%2Fmain%2Fjava%2Forg%2Fldk%2Fstructs%2FRetry.java;h=166f11e6c2bde2257b2d5393802bdec8b46b42e5;hb=94769d9a2cfac383d62769f096674b9f7a7f25df;hp=dc1274e9c8165d99ef095f13d26a316635264a66;hpb=3c60e0fd0da579be9932801c1be2b32014c944a5;p=ldk-java diff --git a/src/main/java/org/ldk/structs/Retry.java b/src/main/java/org/ldk/structs/Retry.java index dc1274e9..166f11e6 100644 --- a/src/main/java/org/ldk/structs/Retry.java +++ b/src/main/java/org/ldk/structs/Retry.java @@ -9,7 +9,7 @@ import javax.annotation.Nullable; /** - * Strategies available to retry payment path failures for an [`Invoice`]. + * Strategies available to retry payment path failures. */ @SuppressWarnings("unchecked") // We correctly assign various generic arrays public class Retry extends CommonBase { @@ -33,9 +33,9 @@ public class Retry extends CommonBase { /** * Max number of attempts to retry payment. * - * Note that this is the number of *path* failures, not full payment retries. For multi-path - * payments, if this is less than the total number of paths, we will never even retry all of the - * payment's paths. + * Each attempt may be multiple HTLCs along multiple paths if the router decides to split up a + * retry, and may retry multiple failed HTLCs at once if they failed around the same time and + * were retried along a route from a single call to [`Router::find_route_with_id`]. */ public final static class Attempts extends Retry { public final long attempts; @@ -45,7 +45,10 @@ public class Retry extends CommonBase { } } /** - * Time elapsed before abandoning retries for a payment. + * Time elapsed before abandoning retries for a payment. At least one attempt at payment is made; + * see [`PaymentParameters::expiry_time`] to avoid any attempt at payment after a specific time. + * + * [`PaymentParameters::expiry_time`]: crate::routing::router::PaymentParameters::expiry_time */ public final static class Timeout extends Retry { public final long timeout; @@ -100,7 +103,7 @@ public class Retry extends CommonBase { * Checks if two Retrys contain equal inner contents. * This ignores pointers and is_owned flags and looks at the values in fields. */ - public boolean eq(Retry b) { + public boolean eq(org.ldk.structs.Retry b) { boolean ret = bindings.Retry_eq(this.ptr, b == null ? 0 : b.ptr); Reference.reachabilityFence(this); Reference.reachabilityFence(b);