Response.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 1996-2021 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 /* DEBUG: section 16 Cache Manager API */
10 
11 #ifndef SQUID_MGR_RESPONSE_H
12 #define SQUID_MGR_RESPONSE_H
13 
14 #include "ipc/forward.h"
15 #include "ipc/Response.h"
16 #include "mgr/Action.h"
17 
18 namespace Mgr
19 {
20 
23 class Response: public Ipc::Response
24 {
25 public:
27  Response(Ipc::RequestId, Action::Pointer anAction = nullptr);
28 
29  explicit Response(const Ipc::TypedMsgHdr& msg);
30 
31  /* Ipc::Response API */
32  virtual void pack(Ipc::TypedMsgHdr& msg) const;
33  virtual Ipc::Response::Pointer clone() const;
34 
35  bool hasAction() const;
36  const Action& getAction() const;
37 
38 public:
40 };
41 
42 } // namespace Mgr
43 
44 #endif /* SQUID_MGR_RESPONSE_H */
45 
Action::Pointer action
action relating to response
Definition: Response.h:39
virtual void pack(Ipc::TypedMsgHdr &msg) const
prepare for sendmsg()
Definition: Response.cc:43
A response to Ipc::Request.
Definition: Response.h:24
virtual Ipc::Response::Pointer clone() const
returns a copy of this
Definition: Response.cc:55
const Action & getAction() const
returns action object
Definition: Response.cc:67
bool hasAction() const
whether response contain action object
Definition: Response.cc:61
struct msghdr with a known type, fixed-size I/O and control buffers
Definition: TypedMsgHdr.h:33
Response()=default
recipient's constructor
Cache Manager API.
Definition: Action.h:20

 

Introduction

Documentation

Support

Miscellaneous

Web Site Translations

Mirrors