Package org.ldk.structs
Class MessageRouter
- java.lang.Object
-
- org.ldk.structs.MessageRouter
-
public class MessageRouter extends Object
A trait defining behavior for routing an [`OnionMessage`]. [`OnionMessage`]: msgs::OnionMessage
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interfaceMessageRouter.MessageRouterInterface
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddestroy()Destroys the object, freeing associated resources.protected voidfinalize()Result_OnionMessagePathNoneZfind_path(byte[] sender, byte[][] peers, Destination destination)Returns a route for sending an [`OnionMessage`] to the given [`Destination`].static MessageRouternew_impl(MessageRouter.MessageRouterInterface arg)
-
-
-
Method Detail
-
finalize
protected void finalize() throws Throwable
-
destroy
public void destroy()
Destroys the object, freeing associated resources. After this call, any access to this object may result in a SEGFAULT or worse. You should generally NEVER call this method. You should let the garbage collector do this for you when it finalizes objects. However, it may be useful for types which represent locks and should be closed immediately to avoid holding locks until the GC runs.
-
new_impl
public static MessageRouter new_impl(MessageRouter.MessageRouterInterface arg)
-
find_path
public Result_OnionMessagePathNoneZ find_path(byte[] sender, byte[][] peers, Destination destination)
Returns a route for sending an [`OnionMessage`] to the given [`Destination`]. [`OnionMessage`]: msgs::OnionMessage
-
-