Skip to content

Commit

Permalink
IUDP.ClientTo -> Remove impl. methods to send data and event to custo…
Browse files Browse the repository at this point in the history
…m target (host)

IUDP.ClientTo -> Remove impl. methods to send data and event to custom target (host)
  • Loading branch information
alec1o committed Jul 1, 2024
1 parent 069d8b9 commit cddab5f
Showing 1 changed file with 0 additions and 42 deletions.
42 changes: 0 additions & 42 deletions src/udp/partials/UDP.ClientTo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -128,34 +128,13 @@ public void Data(string data)
Send(data.GetBytes());
}

public void Data(Host targetHost, byte[] data)
{
if (!IsOpened || targetHost == null || data == null) return;

Send(targetHost, data);
}

public void Data(Host targetHost, string data)
{
if (!IsOpened || targetHost == null || data == null) return;

Send(targetHost, data.GetBytes());
}

public void Data(string data, Encoding encoding)
{
if (!IsOpened || data == null) return;

Send(data.GetBytes(encoding));
}

public void Data(Host targetHost, string data, Encoding encoding)
{
if (!IsOpened || targetHost == null || data == null) return;

Send(targetHost, data.GetBytes(encoding));
}

public void Event(string name, byte[] data)
{
if (!IsOpened || name == null || data == null) return;
Expand All @@ -170,34 +149,13 @@ public void Event(string name, string data)
Send(NetlyEnvironment.EventManager.Create(name, data.GetBytes()));
}

public void Event(Host targetHost, string name, byte[] data)
{
if (!IsOpened || targetHost == null || name == null || data == null) return;

Send(targetHost, NetlyEnvironment.EventManager.Create(name, data));
}

public void Event(Host targetHost, string name, string data)
{
if (!IsOpened || targetHost == null || name == null || data == null) return;

Send(targetHost, NetlyEnvironment.EventManager.Create(name, data.GetBytes()));
}

public void Event(string name, string data, Encoding encoding)
{
if (!IsOpened || name == null || data == null) return;

Send(NetlyEnvironment.EventManager.Create(name, data.GetBytes(encoding)));
}

public void Event(Host targetHost, string name, string data, Encoding encoding)
{
if (!IsOpened || targetHost == null || name == null || data == null) return;

Send(targetHost, NetlyEnvironment.EventManager.Create(name, data.GetBytes(encoding)));
}

public void InitServerSide()
{
if (!_isServer || _initServerSide) return;
Expand Down

0 comments on commit cddab5f

Please sign in to comment.