[Modify] Remove it

This commit is contained in:
sta 2021-09-28 19:08:12 +09:00
parent af895d5f33
commit 00b94045dc

View File

@ -554,48 +554,6 @@ namespace WebSocketSharp.Server
} }
} }
/// <summary>
/// Sends <paramref name="data"/> asynchronously to every client in
/// the WebSocket services.
/// </summary>
/// <remarks>
/// This method does not wait for the send to be complete.
/// </remarks>
/// <param name="data">
/// An array of <see cref="byte"/> that represents the binary data to send.
/// </param>
/// <param name="completed">
/// <para>
/// An <see cref="Action"/> delegate or <see langword="null"/>
/// if not needed.
/// </para>
/// <para>
/// The delegate invokes the method called when the send is complete.
/// </para>
/// </param>
/// <exception cref="InvalidOperationException">
/// The current state of the manager is not Start.
/// </exception>
/// <exception cref="ArgumentNullException">
/// <paramref name="data"/> is <see langword="null"/>.
/// </exception>
[Obsolete ("This method will be removed.")]
public void BroadcastAsync (byte[] data, Action completed)
{
if (_state != ServerState.Start) {
var msg = "The current state of the manager is not Start.";
throw new InvalidOperationException (msg);
}
if (data == null)
throw new ArgumentNullException ("data");
if (data.LongLength <= WebSocket.FragmentLength)
broadcastAsync (Opcode.Binary, data, completed);
else
broadcastAsync (Opcode.Binary, new MemoryStream (data), completed);
}
/// <summary> /// <summary>
/// Sends <paramref name="data"/> asynchronously to every client in /// Sends <paramref name="data"/> asynchronously to every client in
/// the WebSocket services. /// the WebSocket services.