Skip to content

Commit c9b29a3

Browse files
committed
Minor style fixes
1 parent cb0071d commit c9b29a3

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

README.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -18,15 +18,15 @@ This API mirrors (as close as possible) the official .NET [System.Net.WebSockets
1818

1919
## Samples
2020

21-
### WebSockets Server Sample
21+
### WebSockets Server Sample
2222

2323
[Server.RgbSample](https://github.com/nanoframework/Samples/tree/main/samples/WebSockets/WebSockets.Server.RgbSample) shows howto use Websocket Server with a Webserver hosting a WebApp that controlls the rgb led on an Atom Lite ESP32.
2424

25-
### WebSockets Client Sample
25+
### WebSockets Client Sample
2626

2727
[Client.Sample](https://github.com/nanoframework/Samples/tree/main/samples/WebSockets/Websockets.ServerClient.Sample) shows how to use the Websocket Client.
2828

29-
### WebSockets Server and Client sample
29+
### WebSockets Server and Client sample
3030

3131
[ServerClient.Sample](https://github.com/nanoframework/Samples/tree/main/samples/WebSockets/Websockets.ServerClient.Sample) shows how to configure and start a WebSocket Server and (ssl) Client.
3232

@@ -99,7 +99,7 @@ namespace NFWebsocketTestClient
9999

100100
The connection state can be monitored by checking the ClientWebSocket `State`. After the connection is established the state is set to `Open`. The client is only able to send messages if the state is Open.
101101

102-
#### Receiving messages
102+
#### Receiving messages from server
103103

104104
Messages can be received by setting an event handler for `MessageReceived`. This handler will be called every time a message is received. The `MesageReceivedArguments` contains the `MessageReceivedFrame` with a buffer containing the message.
105105

@@ -122,7 +122,7 @@ Whenever a connection is closed the event `Closed` is fired.
122122

123123
The `WebSocketServer` is a websocket host for .NET nanoFramework that can handle multiple websocket connections. The server can be run stand alone or be integrated with the nanoFramework [HttpListner](https://github.com/nanoframework/System.Net.Http/blob/develop/nanoFramework.System.Net.Http/Http/System.Net.HttpListener.cs) or [WebServer](https://github.com/nanoframework/nanoFramework.WebServer).
124124
The server shares a common websocket base with the Client implementation.
125-
125+
126126
#### Creating a server
127127

128128
To start a new server, create a `WebsocketServer` with optional `WebSocketServerOptions`. By default this will start a selfhosted server on port 80, by setting the `Prefix` and `Port` options you can specify on what port and what prefix this server will listen. The default prefix is `/`. It's recommended to set the `MaxClients` to make sure the server does not run out of resources.
@@ -176,7 +176,7 @@ When a client connection is closed the `WebsocketClosed` event is called again c
176176

177177
You can close a specific client connection by calling `DisconnectClient`. You need to specify what client you want to disconnect by providing the client endpoint. Also you need to specify an appropriate `WebSocketCloseStatus`.
178178

179-
#### Receiving messages
179+
#### Receiving messages from clients
180180

181181
When a message from any client is received the `MessageReceived` is raised. Please see the Client section [Receiving Messages](#receiving_messages) and [Message Frame](#message_frame) on how to handle messages. The client who send the message can be identified by checking `Endpoint` property of the `MessageFrame`.
182182

@@ -207,6 +207,6 @@ The **nanoFramework** Class Libraries are licensed under the [MIT license](LICEN
207207
This project has adopted the code of conduct defined by the Contributor Covenant to clarify expected behaviour in our community.
208208
For more information see the [.NET Foundation Code of Conduct](https://dotnetfoundation.org/code-of-conduct).
209209

210-
### .NET Foundation
210+
## .NET Foundation
211211

212212
This project is supported by the [.NET Foundation](https://dotnetfoundation.org).

0 commit comments

Comments
 (0)