## TcpListener::AcceptSocket method


Accepts the pending connection request and returns the socket that is used to send and receive data.

```cpp
System::SharedPtr<Socket> System::Net::Sockets::TcpListener::AcceptSocket()
```


### ReturnValue

The socket that is used for sending and receiving data.

## See Also

* Typedef [SharedPtr](../../../system/sharedptr/)
* Class [Socket](../../socket/)
* Class [TcpListener](../)
* Namespace [System::Net::Sockets](../../)
* Library [Aspose.PDF for C++](../../../)
