diff options
author | Karen Arutyunov <karen@codesynthesis.com> | 2019-05-29 19:02:06 +0300 |
---|---|---|
committer | Karen Arutyunov <karen@codesynthesis.com> | 2019-05-29 19:02:06 +0300 |
commit | ce1399d1610771c5ecca49586dccd89e00427515 (patch) | |
tree | 264f2eb0afe5f003283ea77068051b74a1a2d620 /libbpkg/manifest.hxx | |
parent | d40d439ed96e441fdf74ed9c8073e8941100254e (diff) |
Inherit url type from butl::url
Diffstat (limited to 'libbpkg/manifest.hxx')
-rw-r--r-- | libbpkg/manifest.hxx | 19 |
1 files changed, 16 insertions, 3 deletions
diff --git a/libbpkg/manifest.hxx b/libbpkg/manifest.hxx index 59c0ba0..01ffa49 100644 --- a/libbpkg/manifest.hxx +++ b/libbpkg/manifest.hxx @@ -250,16 +250,29 @@ namespace bpkg }; // url + // doc-url + // src-url // package-url // - class url: public std::string + // URL that has the following constraints: + // + // - is not rootless + // - is not local (the scheme is not `file`) + // - authority is present and is not empty + // + // See libbutl/url.mxx for details. + // + class url: public butl::url { public: std::string comment; + // Throw invalid_argument on parsing or constraints checking error. + // explicit - url (std::string u = "", std::string c = "") - : std::string (std::move (u)), comment (std::move (c)) {} + url (const std::string& u, std::string c = ""); + + url () = default; }; // email |