mirror of https://github.com/deavminet/dnetd.git
Add server instance
This commit is contained in:
parent
878a59920b
commit
616d063516
|
@ -1,19 +1,25 @@
|
||||||
module dnetd.dlistener;
|
module dnetd.dlistener;
|
||||||
|
|
||||||
import std.socket;
|
import std.socket;
|
||||||
|
import dnetd.dserver;
|
||||||
|
|
||||||
public final class DListener
|
public final class DListener
|
||||||
{
|
{
|
||||||
|
/* Associated server */
|
||||||
|
private DServer server;
|
||||||
|
|
||||||
/* The socket */
|
/* The socket */
|
||||||
private Socket socket;
|
private Socket socket;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Creates new listener with the associated server
|
* Creates new listener with the associated server
|
||||||
* and the given Add
|
* and listens on the given address
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
this(AddressInfo addressInfo)
|
this(DServer server, AddressInfo addressInfo)
|
||||||
{
|
{
|
||||||
|
/* Set the server */
|
||||||
|
this.server = server;
|
||||||
|
|
||||||
// /* Get the Address */
|
// /* Get the Address */
|
||||||
// Address address = addressInfo.address;
|
// Address address = addressInfo.address;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue