You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mesos.apache.org by ji...@apache.org on 2016/01/19 01:12:34 UTC

[3/9] mesos git commit: Added a utility function to create https URI.

Added a utility function to create https URI.

Review: https://reviews.apache.org/r/42236


Project: http://git-wip-us.apache.org/repos/asf/mesos/repo
Commit: http://git-wip-us.apache.org/repos/asf/mesos/commit/6815d3f5
Tree: http://git-wip-us.apache.org/repos/asf/mesos/tree/6815d3f5
Diff: http://git-wip-us.apache.org/repos/asf/mesos/diff/6815d3f5

Branch: refs/heads/master
Commit: 6815d3f529a60520e4f2db256db76f34155834f8
Parents: c6a2f8a
Author: Jie Yu <yu...@gmail.com>
Authored: Sun Jan 10 22:10:18 2016 -0800
Committer: Jie Yu <yu...@gmail.com>
Committed: Mon Jan 18 16:09:14 2016 -0800

----------------------------------------------------------------------
 src/uri/schemes/http.hpp | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/mesos/blob/6815d3f5/src/uri/schemes/http.hpp
----------------------------------------------------------------------
diff --git a/src/uri/schemes/http.hpp b/src/uri/schemes/http.hpp
index 84a80b9..a35f175 100644
--- a/src/uri/schemes/http.hpp
+++ b/src/uri/schemes/http.hpp
@@ -44,6 +44,22 @@ inline URI http(
   return construct("http", path, host, port, query, fragment, user, password);
 }
 
+
+/**
+ * Creates an https URI with the given parameters.
+ */
+inline URI https(
+    const std::string& host,
+    const std::string& path = "/",
+    const Option<int>& port = None(),
+    const Option<std::string>& query = None(),
+    const Option<std::string>& fragment = None(),
+    const Option<std::string>& user = None(),
+    const Option<std::string>& password = None())
+{
+  return construct("https", path, host, port, query, fragment, user, password);
+}
+
 } // namespace uri {
 } // namespace mesos {