summaryrefslogtreecommitdiffstats
path: root/tools/android/common/adb_connection.h
diff options
context:
space:
mode:
Diffstat (limited to 'tools/android/common/adb_connection.h')
-rw-r--r--tools/android/common/adb_connection.h19
1 files changed, 19 insertions, 0 deletions
diff --git a/tools/android/common/adb_connection.h b/tools/android/common/adb_connection.h
new file mode 100644
index 0000000..48a1a6f
--- /dev/null
+++ b/tools/android/common/adb_connection.h
@@ -0,0 +1,19 @@
+// Copyright (c) 2012 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 TOOLS_ANDROID_COMMON_ADB_CONNECTION_H__
+#define TOOLS_ANDROID_COMMON_ADB_CONNECTION_H__
+#pragma once
+
+namespace tools {
+
+// Creates a socket that can forward to a host socket through ADB.
+// The format of forward_to is <port>:<ip_address>.
+// Returns the socket handle, or -1 on any error.
+int ConnectAdbHostSocket(const char* forward_to);
+
+} // namespace tools
+
+#endif // TOOLS_ANDROID_COMMON_ADB_CONNECTION_H__
+