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

Unified Diff: mojo/public/cpp/bindings/lib/pipe_control_message_handler.h

Issue 2114523002: Move more Mojo bindings helpers out of internal namespace (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@group-controller
Patch Set: rebase Created 4 years, 6 months 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 side-by-side diff with in-line comments
Download patch
Index: mojo/public/cpp/bindings/lib/pipe_control_message_handler.h
diff --git a/mojo/public/cpp/bindings/lib/pipe_control_message_handler.h b/mojo/public/cpp/bindings/lib/pipe_control_message_handler.h
deleted file mode 100644
index 5d9228d6c3a533d349128a9e2388f71d3d0dd83f..0000000000000000000000000000000000000000
--- a/mojo/public/cpp/bindings/lib/pipe_control_message_handler.h
+++ /dev/null
@@ -1,55 +0,0 @@
-// Copyright 2015 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef MOJO_PUBLIC_CPP_BINDINGS_LIB_PIPE_CONTROL_MESSAGE_HANDLER_H_
-#define MOJO_PUBLIC_CPP_BINDINGS_LIB_PIPE_CONTROL_MESSAGE_HANDLER_H_
-
-#include "base/macros.h"
-#include "mojo/public/cpp/bindings/interface_id.h"
-#include "mojo/public/cpp/bindings/lib/serialization_context.h"
-#include "mojo/public/cpp/bindings/message.h"
-
-namespace mojo {
-namespace internal {
-
-class PipeControlMessageHandlerDelegate;
-
-// Handler for messages defined in pipe_control_messages.mojom.
-class PipeControlMessageHandler : public MessageReceiver {
- public:
- explicit PipeControlMessageHandler(
- PipeControlMessageHandlerDelegate* delegate);
- ~PipeControlMessageHandler() override;
-
- // Sets the description for this handler. Used only when reporting validation
- // errors.
- void SetDescription(const std::string& description);
-
- // NOTE: |message| must have passed message header validation.
- static bool IsPipeControlMessage(const Message* message);
-
- // MessageReceiver implementation:
-
- // NOTE: |message| must:
- // - have passed message header validation; and
- // - be a pipe control message (i.e., IsPipeControlMessage() returns true).
- // If the method returns false, the message pipe should be closed.
- bool Accept(Message* message) override;
-
- private:
- // |message| must have passed message header validation.
- bool Validate(Message* message);
- bool RunOrClosePipe(Message* message);
-
- std::string description_;
- PipeControlMessageHandlerDelegate* const delegate_;
- SerializationContext context_;
-
- DISALLOW_COPY_AND_ASSIGN(PipeControlMessageHandler);
-};
-
-} // namespace internal
-} // namespace mojo
-
-#endif // MOJO_PUBLIC_CPP_BINDINGS_LIB_PIPE_CONTROL_MESSAGE_HANDLER_H_
« no previous file with comments | « mojo/public/cpp/bindings/lib/multiplex_router.cc ('k') | mojo/public/cpp/bindings/lib/pipe_control_message_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698