diff --git a/source/doap/client/client.d b/source/doap/client/client.d index 35a7c83..6f0d78d 100644 --- a/source/doap/client/client.d +++ b/source/doap/client/client.d @@ -17,7 +17,7 @@ public class CoapClient /** * CoAP server endpoint */ - private Address address; + package Address address; /** * Running status diff --git a/source/doap/client/messaging.d b/source/doap/client/messaging.d index f27f1fa..2c13d70 100644 --- a/source/doap/client/messaging.d +++ b/source/doap/client/messaging.d @@ -11,6 +11,7 @@ import doap.client.request : CoapRequest; import std.stdio; import std.socket : Socket, SocketSet; +import std.socket : Address; // TODO: Generalize this and then make // ... a UDP version of it @@ -42,6 +43,11 @@ class CoapMessagingLayer : Thread this.client = client; } + public final Address getEndpointAddress() + { + return this.client.address; + } + /** * Reading loop which reads datagrams * from the socket