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

Unified Diff: blimp/net/client_auth_handler.h

Issue 1501463003: [Blimp Net] Client sends START_CONNECTION message (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years 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
« no previous file with comments | « blimp/net/BUILD.gn ('k') | blimp/net/client_auth_handler.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: blimp/net/client_auth_handler.h
diff --git a/blimp/net/client_auth_handler.h b/blimp/net/client_auth_handler.h
new file mode 100644
index 0000000000000000000000000000000000000000..05a1afc14f837cfb55754e8ca12780f8ae78a7c4
--- /dev/null
+++ b/blimp/net/client_auth_handler.h
@@ -0,0 +1,46 @@
+// 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 BLIMP_NET_CLIENT_AUTH_HANDLER_H_
+#define BLIMP_NET_CLIENT_AUTH_HANDLER_H_
+
+#include <vector>
+
+#include "base/macros.h"
+#include "base/memory/scoped_ptr.h"
+#include "base/timer/timer.h"
+#include "blimp/net/blimp_net_export.h"
+#include "blimp/net/connection_handler.h"
+
+namespace blimp {
+
+class BlimpConnection;
+class BlimpMessage;
+
+// Sends authenticate message to the engine and hand connections over to
+// |connection_handler| right away.
+class BLIMP_NET_EXPORT ClientAuthHandler : public ConnectionHandler {
Wez 2015/12/04 01:40:28 See comments re EngineAuthHandler naming. Based o
+ public:
+ // Caller is responsible for ensuring that |connection_handler| outlives
+ // |this|.
+ explicit ClientAuthHandler(ConnectionHandler* connection_handler);
+
+ ~ClientAuthHandler() override;
+
+ // ConnectionHandler implementation.
+ void HandleConnection(scoped_ptr<BlimpConnection> connection) override;
+
+ private:
+ // Gathers client token and checkpoints and creates a blimp message to
+ // send to the engine.
+ scoped_ptr<BlimpMessage> CreateAuthMessage();
+
+ ConnectionHandler* connection_handler_;
+
+ DISALLOW_COPY_AND_ASSIGN(ClientAuthHandler);
+};
+
+} // namespace blimp
+
+#endif // BLIMP_NET_CLIENT_AUTH_HANDLER_H_
« no previous file with comments | « blimp/net/BUILD.gn ('k') | blimp/net/client_auth_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698