ap

Dependencies:   DnsQuery

Dependents:   WizFi310_TCP_Echo_Server_Example

Fork of NetworkSocketAPI by NetworkSocketAPI

Branch:
api-changes
Revision:
24:a5e959bdd2dd
Parent:
22:4fca633c0633
Child:
25:ed7b2a52e8ac
--- a/UDPSocket.cpp	Thu Feb 18 04:05:09 2016 -0600
+++ b/UDPSocket.cpp	Thu Feb 18 04:09:00 2016 -0600
@@ -16,11 +16,11 @@
 
 #include "UDPSocket.h"
 
-UDPSocket::UDPSocket(NetworkInterface *iface, const char *ip, uint16_t port)
+UDPSocket::UDPSocket(NetworkInterface *iface, const char *url, uint16_t port)
   : _iface(iface) {
     _socket = _iface->createSocket(SOCK_UDP);
 
-    if (ip)   setIPAddress(ip);
+    if (url)  setURL(url);
     if (port) setPort(port);
 }
 
@@ -28,6 +28,10 @@
     _iface->destroySocket(_socket);
 }
 
+void UDPSocket::setURL(const char *url) {
+    return _socket->setURL(url);
+}
+
 void UDPSocket::setIPAddress(const char *ip) {
     return _socket->setIPAddress(ip);
 }