AWS SDK for C++

AWS SDK for C++ Version 1.11.717

Loading...
Searching...
No Matches
Geometry.h
1
6#pragma once
7#include <aws/core/utils/memory/stl/AWSVector.h>
8#include <aws/textract/Textract_EXPORTS.h>
9#include <aws/textract/model/BoundingBox.h>
10#include <aws/textract/model/Point.h>
11
12#include <utility>
13
14namespace Aws {
15namespace Utils {
16namespace Json {
17class JsonValue;
18class JsonView;
19} // namespace Json
20} // namespace Utils
21namespace Textract {
22namespace Model {
23
31class Geometry {
32 public:
33 AWS_TEXTRACT_API Geometry() = default;
34 AWS_TEXTRACT_API Geometry(Aws::Utils::Json::JsonView jsonValue);
35 AWS_TEXTRACT_API Geometry& operator=(Aws::Utils::Json::JsonView jsonValue);
36 AWS_TEXTRACT_API Aws::Utils::Json::JsonValue Jsonize() const;
37
39
43 inline const BoundingBox& GetBoundingBox() const { return m_boundingBox; }
44 inline bool BoundingBoxHasBeenSet() const { return m_boundingBoxHasBeenSet; }
45 template <typename BoundingBoxT = BoundingBox>
46 void SetBoundingBox(BoundingBoxT&& value) {
47 m_boundingBoxHasBeenSet = true;
48 m_boundingBox = std::forward<BoundingBoxT>(value);
49 }
50 template <typename BoundingBoxT = BoundingBox>
51 Geometry& WithBoundingBox(BoundingBoxT&& value) {
52 SetBoundingBox(std::forward<BoundingBoxT>(value));
53 return *this;
54 }
56
58
62 inline const Aws::Vector<Point>& GetPolygon() const { return m_polygon; }
63 inline bool PolygonHasBeenSet() const { return m_polygonHasBeenSet; }
64 template <typename PolygonT = Aws::Vector<Point>>
65 void SetPolygon(PolygonT&& value) {
66 m_polygonHasBeenSet = true;
67 m_polygon = std::forward<PolygonT>(value);
68 }
69 template <typename PolygonT = Aws::Vector<Point>>
70 Geometry& WithPolygon(PolygonT&& value) {
71 SetPolygon(std::forward<PolygonT>(value));
72 return *this;
73 }
74 template <typename PolygonT = Point>
75 Geometry& AddPolygon(PolygonT&& value) {
76 m_polygonHasBeenSet = true;
77 m_polygon.emplace_back(std::forward<PolygonT>(value));
78 return *this;
79 }
81
83
86 inline double GetRotationAngle() const { return m_rotationAngle; }
87 inline bool RotationAngleHasBeenSet() const { return m_rotationAngleHasBeenSet; }
88 inline void SetRotationAngle(double value) {
89 m_rotationAngleHasBeenSet = true;
90 m_rotationAngle = value;
91 }
92 inline Geometry& WithRotationAngle(double value) {
93 SetRotationAngle(value);
94 return *this;
95 }
97 private:
98 BoundingBox m_boundingBox;
99
100 Aws::Vector<Point> m_polygon;
101
102 double m_rotationAngle{0.0};
103 bool m_boundingBoxHasBeenSet = false;
104 bool m_polygonHasBeenSet = false;
105 bool m_rotationAngleHasBeenSet = false;
106};
107
108} // namespace Model
109} // namespace Textract
110} // namespace Aws
Geometry & WithRotationAngle(double value)
Definition Geometry.h:92
Geometry & WithPolygon(PolygonT &&value)
Definition Geometry.h:70
const BoundingBox & GetBoundingBox() const
Definition Geometry.h:43
bool RotationAngleHasBeenSet() const
Definition Geometry.h:87
AWS_TEXTRACT_API Aws::Utils::Json::JsonValue Jsonize() const
bool BoundingBoxHasBeenSet() const
Definition Geometry.h:44
Geometry & AddPolygon(PolygonT &&value)
Definition Geometry.h:75
AWS_TEXTRACT_API Geometry(Aws::Utils::Json::JsonView jsonValue)
void SetRotationAngle(double value)
Definition Geometry.h:88
AWS_TEXTRACT_API Geometry & operator=(Aws::Utils::Json::JsonView jsonValue)
void SetBoundingBox(BoundingBoxT &&value)
Definition Geometry.h:46
void SetPolygon(PolygonT &&value)
Definition Geometry.h:65
double GetRotationAngle() const
Definition Geometry.h:86
Geometry & WithBoundingBox(BoundingBoxT &&value)
Definition Geometry.h:51
const Aws::Vector< Point > & GetPolygon() const
Definition Geometry.h:62
AWS_TEXTRACT_API Geometry()=default
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue