Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(279)

Side by Side Diff: chrome/browser/renderer_host/global_request_id.h

Issue 460108: Implement ResourceQueue, an object that makes it easy to delay starting (Closed)
Patch Set: nitfixing Created 11 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef CHROME_BROWSER_RENDERER_HOST_GLOBAL_REQUEST_ID_H_
6 #define CHROME_BROWSER_RENDERER_HOST_GLOBAL_REQUEST_ID_H_
7
8 // Uniquely identifies a URLRequest.
9 struct GlobalRequestID {
10 GlobalRequestID() : child_id(-1), request_id(-1) {
11 }
12
13 GlobalRequestID(int child_id, int request_id)
14 : child_id(child_id),
15 request_id(request_id) {
16 }
17
18 // The unique ID of the child process (different from OS's PID).
19 int child_id;
20
21 // The request ID (unique for the child).
22 int request_id;
23
24 bool operator<(const GlobalRequestID& other) const {
25 if (child_id == other.child_id)
26 return request_id < other.request_id;
27 return child_id < other.child_id;
28 }
29 };
30
31 #endif // CHROME_BROWSER_RENDERER_HOST_GLOBAL_REQUEST_ID_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698