aws-crt-cpp
C++ wrapper around the aws-c-* libraries. Provides Cross-Platform Transport Protocols and SSL/TLS implementations for C++.
Uri.h
Go to the documentation of this file.
1#pragma once
6#include <aws/crt/Types.h>
7
8#include <aws/io/uri.h>
9
10namespace Aws
11{
12 namespace Crt
13 {
14 namespace Io
15 {
19 class AWS_CRT_CPP_API Uri final
20 {
21 public:
22 Uri() noexcept;
23 ~Uri();
28 Uri(const ByteCursor &cursor, Allocator *allocator = g_allocator) noexcept;
33 Uri(aws_uri_builder_options &builderOptions, Allocator *allocator = g_allocator) noexcept;
34 Uri(const Uri &);
35 Uri &operator=(const Uri &);
36 Uri(Uri &&uri) noexcept;
37 Uri &operator=(Uri &&) noexcept;
41 operator bool() const noexcept { return m_isInit; }
45 int LastError() const noexcept { return m_lastError; }
46
50 ByteCursor GetScheme() const noexcept;
51
56 ByteCursor GetAuthority() const noexcept;
57
61 ByteCursor GetPath() const noexcept;
62
66 ByteCursor GetQueryString() const noexcept;
67
71 ByteCursor GetHostName() const noexcept;
72
78 uint16_t GetPort() const noexcept;
79
83 ByteCursor GetPathAndQuery() const noexcept;
84
88 ByteCursor GetFullUri() const noexcept;
89
90 private:
91 aws_uri m_uri;
92 int m_lastError;
93 bool m_isInit;
94 };
95 } // namespace Io
96 } // namespace Crt
97} // namespace Aws
#define AWS_CRT_CPP_API
Definition: Exports.h:37
Definition: Uri.h:20
int LastError() const noexcept
Definition: Uri.h:45
aws_byte_cursor ByteCursor
Definition: Types.h:33
aws_allocator Allocator
Definition: StlAllocator.h:17
AWS_CRT_CPP_API Allocator * g_allocator
Definition: Api.cpp:21
Definition: Api.h:17