25#include <kcenon/common/patterns/result.h>
95 -> container_module::optimized_value;
131 -> std::shared_ptr<container_module::value_container>;
143 const container_module::value_container& container)
160 -> std::vector<uint8_t>;
171 [[nodiscard]]
static auto from_binary(std::span<const uint8_t> data)
185 -> container_module::value_types;
250 -> std::optional<std::pair<core::dicom_tag, encoding::vr_type>>;
260 -> std::shared_ptr<container_module::value_container>;
269 const container_module::value_container& container)
270 -> std::vector<core::dicom_dataset>;
static auto serialize_dataset(const core::dicom_dataset &dataset) -> std::shared_ptr< container_module::value_container >
Serialize a DICOM dataset to a value_container.
static constexpr std::string_view kProtocolVersion
Protocol version for serialization format.
static constexpr auto maps_to_binary(encoding::vr_type vr) noexcept -> bool
Check if a VR maps to binary data.
static auto from_binary(std::span< const uint8_t > data) -> Result< core::dicom_dataset >
Deserialize binary data back to a DICOM dataset.
static auto from_container_value(core::dicom_tag tag, encoding::vr_type vr, const container_module::optimized_value &val) -> core::dicom_element
Convert a container value back to a DICOM element.
static auto sequence_to_container(const core::dicom_element &element) -> std::shared_ptr< container_module::value_container >
Convert sequence items to container array.
static auto to_binary(const core::dicom_dataset &dataset) -> std::vector< uint8_t >
Serialize a DICOM dataset to binary format.
static constexpr std::string_view kElementCountKey
Key for element count in container.
static auto to_container_value(const core::dicom_element &element) -> container_module::optimized_value
Convert a DICOM element to a container value.
static auto parse_element_key(std::string_view key) -> std::optional< std::pair< core::dicom_tag, encoding::vr_type > >
Parse an element key back to tag and VR.
static constexpr auto maps_to_string(encoding::vr_type vr) noexcept -> bool
Check if a VR maps to a string value.
static constexpr std::string_view kVersionKey
Key for protocol version in container.
static constexpr auto maps_to_numeric(encoding::vr_type vr) noexcept -> bool
Check if a VR maps to a numeric value.
static auto get_container_type(encoding::vr_type vr) noexcept -> container_module::value_types
Get the container value type for a DICOM VR.
static auto make_element_key(core::dicom_tag tag, encoding::vr_type vr) -> std::string
Create a key string for an element in the container.
static auto container_to_sequence(const container_module::value_container &container) -> std::vector< core::dicom_dataset >
Convert container array back to sequence items.
static auto deserialize_dataset(const container_module::value_container &container) -> Result< core::dicom_dataset >
Deserialize a value_container back to a DICOM dataset.
DICOM Dataset - ordered collection of Data Elements.
DICOM Data Element representation (Tag, VR, Value)
DICOM Tag representation (Group, Element pairs)
constexpr bool is_numeric_vr(vr_type vr) noexcept
Checks if a VR is a numeric type.
constexpr bool is_binary_vr(vr_type vr) noexcept
Checks if a VR is a binary/raw byte type.
vr_type
DICOM Value Representation (VR) types.
constexpr bool is_string_vr(vr_type vr) noexcept
Checks if a VR is a string type.