AWS SDK for C++

AWS SDK for C++ Version 1.11.718

Loading...
Searching...
No Matches
Geometry.h
1
6#pragma once
7#include <aws/comprehend/Comprehend_EXPORTS.h>
8#include <aws/comprehend/model/BoundingBox.h>
9#include <aws/comprehend/model/Point.h>
10#include <aws/core/utils/memory/stl/AWSVector.h>
11
12#include <utility>
13
14namespace Aws {
15namespace Utils {
16namespace Json {
17class JsonValue;
18class JsonView;
19} // namespace Json
20} // namespace Utils
21namespace Comprehend {
22namespace Model {
23
32class Geometry {
33 public:
34 AWS_COMPREHEND_API Geometry() = default;
35 AWS_COMPREHEND_API Geometry(Aws::Utils::Json::JsonView jsonValue);
36 AWS_COMPREHEND_API Geometry& operator=(Aws::Utils::Json::JsonView jsonValue);
37 AWS_COMPREHEND_API Aws::Utils::Json::JsonValue Jsonize() const;
38
40
44 inline const BoundingBox& GetBoundingBox() const { return m_boundingBox; }
45 inline bool BoundingBoxHasBeenSet() const { return m_boundingBoxHasBeenSet; }
46 template <typename BoundingBoxT = BoundingBox>
47 void SetBoundingBox(BoundingBoxT&& value) {
48 m_boundingBoxHasBeenSet = true;
49 m_boundingBox = std::forward<BoundingBoxT>(value);
50 }
51 template <typename BoundingBoxT = BoundingBox>
52 Geometry& WithBoundingBox(BoundingBoxT&& value) {
53 SetBoundingBox(std::forward<BoundingBoxT>(value));
54 return *this;
55 }
57
59
63 inline const Aws::Vector<Point>& GetPolygon() const { return m_polygon; }
64 inline bool PolygonHasBeenSet() const { return m_polygonHasBeenSet; }
65 template <typename PolygonT = Aws::Vector<Point>>
66 void SetPolygon(PolygonT&& value) {
67 m_polygonHasBeenSet = true;
68 m_polygon = std::forward<PolygonT>(value);
69 }
70 template <typename PolygonT = Aws::Vector<Point>>
71 Geometry& WithPolygon(PolygonT&& value) {
72 SetPolygon(std::forward<PolygonT>(value));
73 return *this;
74 }
75 template <typename PolygonT = Point>
76 Geometry& AddPolygon(PolygonT&& value) {
77 m_polygonHasBeenSet = true;
78 m_polygon.emplace_back(std::forward<PolygonT>(value));
79 return *this;
80 }
82 private:
83 BoundingBox m_boundingBox;
84
85 Aws::Vector<Point> m_polygon;
86 bool m_boundingBoxHasBeenSet = false;
87 bool m_polygonHasBeenSet = false;
88};
89
90} // namespace Model
91} // namespace Comprehend
92} // namespace Aws
AWS_COMPREHEND_API Aws::Utils::Json::JsonValue Jsonize() const
const BoundingBox & GetBoundingBox() const
Definition Geometry.h:44
Geometry & AddPolygon(PolygonT &&value)
Definition Geometry.h:76
void SetBoundingBox(BoundingBoxT &&value)
Definition Geometry.h:47
Geometry & WithPolygon(PolygonT &&value)
Definition Geometry.h:71
AWS_COMPREHEND_API Geometry()=default
AWS_COMPREHEND_API Geometry(Aws::Utils::Json::JsonView jsonValue)
void SetPolygon(PolygonT &&value)
Definition Geometry.h:66
Geometry & WithBoundingBox(BoundingBoxT &&value)
Definition Geometry.h:52
const Aws::Vector< Point > & GetPolygon() const
Definition Geometry.h:63
AWS_COMPREHEND_API Geometry & operator=(Aws::Utils::Json::JsonView jsonValue)
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue