Lines Matching refs:Socket
34 Socket::Socket(cutils_socket_t sock) : sock_(sock) {} in Socket() function in Socket
36 Socket::~Socket() { in ~Socket()
40 int Socket::Close() { in Close()
51 ssize_t Socket::ReceiveAll(void* data, size_t length, int timeout_ms) { in ReceiveAll()
71 int Socket::GetLocalPort() { in GetLocalPort()
79 bool Socket::WaitForRecv(int timeout_ms) { in WaitForRecv()
110 class UdpSocket : public Socket {
127 UdpSocket::UdpSocket(Type type, cutils_socket_t sock) : Socket(sock) { in UdpSocket()
170 class TcpSocket : public Socket {
172 explicit TcpSocket(cutils_socket_t sock) : Socket(sock) {} in TcpSocket()
178 std::unique_ptr<Socket> Accept() override;
240 std::unique_ptr<Socket> TcpSocket::Accept() { in Accept()
248 std::unique_ptr<Socket> Socket::NewClient(Protocol protocol, const std::string& host, int port, in NewClient()
269 std::unique_ptr<Socket> Socket::NewServer(Protocol protocol, int port) { in NewServer()
285 std::string Socket::GetErrorMessage() { in GetErrorMessage()