17 Size(int32_t _width, int32_t _height) {
21 Size(
const Size& sz) {
25 Size(Size&& sz)
noexcept {
32 Size& operator = (
const Size& sz) =
default;
33 Size& operator = (Size&& sz)
noexcept {
42 bool operator == (
const Size& other)
const {
43 return width == other.width && height == other.height;
46 int32_t area()
const {
47 return width * height;
50 return width <= 0 || height <= 0;
53 friend std::ostream& operator<<(std::ostream& os,
const Size& size) {
54 os <<
"Size (width: " << size.width <<
", height: " << size.height <<
")";
Definition: exceptions.hpp:15