]> git.ipfire.org Git - thirdparty/squid.git/blob - src/ipc/RequestId.cc
Source Format Enforcement (#1234)
[thirdparty/squid.git] / src / ipc / RequestId.cc
1 /*
2 * Copyright (C) 1996-2023 The Squid Software Foundation and contributors
3 *
4 * Squid software is distributed under GPLv2+ license and includes
5 * contributions from numerous individuals and organizations.
6 * Please see the COPYING and CONTRIBUTORS files for details.
7 */
8
9 #include "squid.h"
10 #include "base/TextException.h"
11 #include "debug/Stream.h"
12 #include "ipc/RequestId.h"
13
14 #include <iostream>
15
16 Ipc::RequestId::RequestId(const Index anIndex):
17 qid_(anIndex ? MyQuestionerId() : QuestionerId()),
18 index_(anIndex)
19 {
20 }
21
22 std::ostream &
23 Ipc::operator <<(std::ostream &os, const RequestId &requestId)
24 {
25 os << requestId.index() << '@' << requestId.questioner();
26 return os;
27 }
28