xtd - Reference Guide  0.1.0
Modern c++17/20 framework to create console, GUI and unit test applications on Windows, macOS, Linux, iOS and android.
Loading...
Searching...
No Matches
property_item.h
Go to the documentation of this file.
1
4#pragma once
5#include <cstdint>
6#include <vector>
7#include <xtd/object.h>
8
10namespace xtd {
12 namespace drawing {
15 namespace imaging {
25 class property_item final : public object {
26 public:
28 property_item() = default;
30
253 int32_t id() const {return id_;}
476 void id(int32_t id) {id_ = id;}
477
480 int32_t len() const {return len_;}
483 void len(int32_t len) {len_ = len;}
484
498 int16_t type() const {return type_;}
512 void type(int16_t type) {type_ = type;}
513
517 const std::vector<uint8_t>& value() const {return value_;}
521 std::vector<uint8_t>& value() {return value_;}
525 void value(const std::vector<uint8_t>& value) {value_ = value;}
526
527 private:
528 int32_t id_ = 0;
529 int32_t len_ = 0;
530 int16_t type_ = 1;
531 std::vector<uint8_t> value_;
532 };
533 }
534 }
535}
Encapsulates a metadata property to be included in an image file. Not inheritable.
Definition: property_item.h:25
int32_t len() const
Gets the length (in bytes) of the value property.
Definition: property_item.h:480
void id(int32_t id)
Sets the ID of the property.
Definition: property_item.h:476
void value(const std::vector< uint8_t > &value)
Sets the value of the property item.
Definition: property_item.h:525
const std::vector< uint8_t > & value() const
Gets the value of the property item.
Definition: property_item.h:517
void len(int32_t len)
Sets the length (in bytes) of the value property. &param len An integer that represents the length (i...
Definition: property_item.h:483
int16_t type() const
Gets an integer that defines the type of data contained in the value property.
Definition: property_item.h:498
int32_t id() const
Gets the ID of the property.
Definition: property_item.h:253
void type(int16_t type)
Sets an integer that defines the type of data contained in the value property.
Definition: property_item.h:512
std::vector< uint8_t > & value()
Gets the value of the property item.
Definition: property_item.h:521
Supports all classes in the xtd class hierarchy and provides low-level services to derived classes....
Definition: object.h:26
std::type_info type
Stores information about a type.
Definition: types.h:179
The xtd namespace contains all fundamental classes to access Hardware, Os, System,...
Definition: system_report.h:17
Contains xtd::object class.