summaryrefslogtreecommitdiffstats
path: root/content/common/p2p_sockets.h
blob: 3c44fd86f85a3dd8501859bfad750ba315cc9b44 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
// Copyright (c) 2011 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

// This file defines some basic types used by the P2P-related IPC
// messages.

#ifndef CONTENT_COMMON_P2P_SOCKETS_H_
#define CONTENT_COMMON_P2P_SOCKETS_H_

#include "net/base/net_util.h"

// Pair of IP address and port number.
struct P2PSocketAddress {
  P2PSocketAddress();
  ~P2PSocketAddress();
  net::IPAddressNumber address;
  int port;
};

// Type of P2P Socket.
enum P2PSocketType {
  P2P_SOCKET_UDP,
  P2P_SOCKET_TCP_SERVER,
  P2P_SOCKET_TCP_CLIENT,
};

#endif  // CONTENT_COMMON_P2P_SOCKETS_H_