Check out example codes for "arduino server read". It will help you in understanding the concepts better.

Code Example 1

Gets a client that is connected to the server and has data available for reading.
 The connection persists when the returned client object goes out of scope; you
 can close it by calling client.stop().

Syntax
server.available()

Learn ReactJs, React Native from akashmittal.com