ipc_sender.h 716 B

12345678910111213141516171819202122232425262728
  1. // Copyright (c) 2012 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. #ifndef IPC_IPC_SENDER_H_
  5. #define IPC_IPC_SENDER_H_
  6. #include "base/component_export.h"
  7. namespace IPC {
  8. class Message;
  9. class COMPONENT_EXPORT(IPC) Sender {
  10. public:
  11. // Sends the given IPC message. The implementor takes ownership of the
  12. // given Message regardless of whether or not this method succeeds. This
  13. // is done to make this method easier to use. Returns true on success and
  14. // false otherwise.
  15. virtual bool Send(Message* msg) = 0;
  16. protected:
  17. virtual ~Sender() {}
  18. };
  19. } // namespace IPC
  20. #endif // IPC_IPC_SENDER_H_