pub struct AnnotationDocument { /* private fields */ }Implementations§
Source§impl AnnotationDocument
impl AnnotationDocument
pub fn new( source: DicomAnnotationContext, groups: Vec<AnnotationGroup>, ) -> Result<Self>
pub fn read_ann( path: impl AsRef<Path>, source: &DicomAnnotationContext, ) -> Result<Self>
pub fn write_ann(&self, path: impl AsRef<Path>) -> Result<()>
pub fn write_ann_with_loss_policy( &self, path: impl AsRef<Path>, allow_lossy: bool, ) -> Result<()>
pub fn revised(&self) -> Self
pub fn revised_with_groups(&self, groups: Vec<AnnotationGroup>) -> Result<Self>
Sourcepub fn with_producer(self, producer: DerivedObjectProducer) -> Self
pub fn with_producer(self, producer: DerivedObjectProducer) -> Self
Replaces the neutral library identity with caller-owned producer metadata.
pub fn producer(&self) -> &DerivedObjectProducer
Sourcepub fn replace_groups(&mut self, groups: Vec<AnnotationGroup>) -> Result<()>
pub fn replace_groups(&mut self, groups: Vec<AnnotationGroup>) -> Result<()>
Atomically replaces all groups after validating group and document invariants.
Sourcepub fn replace_group(
&mut self,
index: usize,
group: AnnotationGroup,
) -> Result<()>
pub fn replace_group( &mut self, index: usize, group: AnnotationGroup, ) -> Result<()>
Atomically replaces one group after validating group and document invariants.
pub fn source(&self) -> &DicomAnnotationContext
pub fn sop_instance_uid(&self) -> &str
pub fn series_instance_uid(&self) -> &str
pub fn predecessor_sop_instance_uid(&self) -> Option<&str>
pub fn supports_2d_volume_editing(&self) -> bool
pub fn coordinate_type(&self) -> &str
pub fn pixel_origin_interpretation(&self) -> Option<&str>
pub const fn referenced_frame_number(&self) -> Option<u32>
pub fn content_label(&self) -> &str
pub fn content_description(&self) -> &str
pub fn content_creator_name(&self) -> Option<&str>
pub fn canonical_level0_pixel( &self, canonical_source: &DicomAnnotationContext, x: f64, y: f64, z: Option<f64>, ) -> Result<Point2>
pub fn groups(&self) -> &[AnnotationGroup]
pub fn diagnostics(&self) -> &[InteroperabilityDiagnostic]
Trait Implementations§
Source§impl Clone for AnnotationDocument
impl Clone for AnnotationDocument
Source§impl Debug for AnnotationDocument
impl Debug for AnnotationDocument
Source§impl PartialEq for AnnotationDocument
impl PartialEq for AnnotationDocument
impl StructuralPartialEq for AnnotationDocument
Auto Trait Implementations§
impl Freeze for AnnotationDocument
impl RefUnwindSafe for AnnotationDocument
impl Send for AnnotationDocument
impl Sync for AnnotationDocument
impl Unpin for AnnotationDocument
impl UnsafeUnpin for AnnotationDocument
impl UnwindSafe for AnnotationDocument
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more