|
Squid Web Cache v8/master
|
#include <ResolvedPeers.h>
Public Types | |
| using | size_type = ResolvedPeers::size_type |
Public Member Functions | |
| PeerConnectionPointer ()=default | |
| PeerConnectionPointer (std::nullptr_t) | |
| implicit nullptr conversion | |
| PeerConnectionPointer (const Comm::ConnectionPointer &conn, const size_type pos) | |
| operator bool () const | |
| Comm::Connection * | operator-> () const |
| Comm::Connection & | operator* () const |
| operator const Comm::ConnectionPointer & () const | |
| convenience conversion to Comm::ConnectionPointer | |
| void | finalize (const Comm::ConnectionPointer &conn) |
| upgrade stored peer selection details with a matching actual connection | |
| void | print (std::ostream &) const |
| debugging dump | |
Private Attributes | |
| Comm::ConnectionPointer | connection_ |
| half-baked, open, failed, or closed Comm::Connection (or nil) | |
| size_type | position_ = npos |
| ResolvedPeers-maintained membership index (or npos) | |
Static Private Attributes | |
| static constexpr auto | npos = std::numeric_limits<size_type>::max() |
| non-existent position for nil connection | |
Friends | |
| class | ResolvedPeers |
An invasive reference-counting Comm::Connection pointer that also keeps an (optional) ResolvedPeers position for the ResolvedPeers::reinstatePath() usage. Reference counting mechanism is compatible with Comm::ConnectionPointer.
Definition at line 121 of file ResolvedPeers.h.
Definition at line 124 of file ResolvedPeers.h.
|
default |
|
inline |
Definition at line 127 of file ResolvedPeers.h.
|
inline |
Definition at line 128 of file ResolvedPeers.h.
|
inline |
Definition at line 139 of file ResolvedPeers.h.
References connection_.
Referenced by HappyConnOpener::handleConnOpenerAnswer(), and HappyConnOpener::reuseOldConnection().
|
inlineexplicit |
Definition at line 131 of file ResolvedPeers.h.
References connection_.
|
inline |
Definition at line 136 of file ResolvedPeers.h.
References connection_.
|
inline |
Definition at line 133 of file ResolvedPeers.h.
References assert, and connection_.
|
inline |
Definition at line 132 of file ResolvedPeers.h.
References assert, connection_, and RefCount< C >::getRaw().
| void PeerConnectionPointer::print | ( | std::ostream & | os | ) | const |
Definition at line 231 of file ResolvedPeers.cc.
References connection_, npos, and position_.
Referenced by operator<<().
|
friend |
Definition at line 153 of file ResolvedPeers.h.
|
private |
Definition at line 149 of file ResolvedPeers.h.
Referenced by finalize(), operator bool(), operator const Comm::ConnectionPointer &(), operator*(), operator->(), and print().
|
staticconstexprprivate |
Definition at line 146 of file ResolvedPeers.h.
Referenced by print().
Definition at line 152 of file ResolvedPeers.h.
Referenced by print(), and ResolvedPeers::reinstatePath().