blob: af1e91742d044d0416d3d6773dd6577cfbd276e1 [file] [log] [blame]
Avi Drissman64595482022-09-14 20:52:291// Copyright 2014 The Chromium Authors
[email protected]cd48ed12014-01-22 14:34:222// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#ifndef NET_WEBSOCKETS_WEBSOCKET_HANDSHAKE_RESPONSE_INFO_H_
6#define NET_WEBSOCKETS_WEBSOCKET_HANDSHAKE_RESPONSE_INFO_H_
7
Bence Béky65623972018-03-05 15:31:568#include "base/memory/scoped_refptr.h"
[email protected]cd48ed12014-01-22 14:34:229#include "base/time/time.h"
Tsuyoshi Horo01faed62019-02-20 22:11:3710#include "net/base/ip_endpoint.h"
[email protected]cd48ed12014-01-22 14:34:2211#include "net/base/net_export.h"
12#include "url/gurl.h"
13
14namespace net {
15
16class HttpResponseHeaders;
17
18struct NET_EXPORT WebSocketHandshakeResponseInfo {
19 WebSocketHandshakeResponseInfo(const GURL& url,
[email protected]cd48ed12014-01-22 14:34:2220 scoped_refptr<HttpResponseHeaders> headers,
Tsuyoshi Horo01faed62019-02-20 22:11:3721 const IPEndPoint& remote_endpoint,
[email protected]cd48ed12014-01-22 14:34:2222 base::Time response_time);
Peter Boström407869b2021-10-07 04:42:4823
24 WebSocketHandshakeResponseInfo(const WebSocketHandshakeResponseInfo&) =
25 delete;
26 WebSocketHandshakeResponseInfo& operator=(
27 const WebSocketHandshakeResponseInfo&) = delete;
28
[email protected]cd48ed12014-01-22 14:34:2229 ~WebSocketHandshakeResponseInfo();
Peter Boström407869b2021-10-07 04:42:4830
[email protected]cd48ed12014-01-22 14:34:2231 // The request URL
32 GURL url;
[email protected]cd48ed12014-01-22 14:34:2233 // HTTP response headers
34 scoped_refptr<HttpResponseHeaders> headers;
Yutaka Hirano36c94952018-05-30 21:33:3335 // Remote address of the socket.
Tsuyoshi Horo01faed62019-02-20 22:11:3736 IPEndPoint remote_endpoint;
[email protected]cd48ed12014-01-22 14:34:2237 // The time that this response arrived
38 base::Time response_time;
[email protected]cd48ed12014-01-22 14:34:2239};
40
41} // namespace net
42
43#endif // NET_WEBSOCKETS_WEBSOCKET_HANDSHAKE_RESPONSE_INFO_H_