#[non_exhaustive]pub struct LabelAnnotation {
pub entity: Option<Entity>,
pub category_entities: Vec<Entity>,
pub segments: Vec<LabelSegment>,
pub frames: Vec<LabelFrame>,
pub version: String,
/* private fields */
}Expand description
Label annotation.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.entity: Option<Entity>Detected entity.
category_entities: Vec<Entity>Common categories for the detected entity.
For example, when the label is Terrier, the category is likely dog. And
in some cases there might be more than one categories e.g., Terrier could
also be a pet.
segments: Vec<LabelSegment>All video segments where a label was detected.
frames: Vec<LabelFrame>All video frames where a label was detected.
version: StringFeature version.
Implementations§
Source§impl LabelAnnotation
impl LabelAnnotation
Sourcepub fn set_entity<T>(self, v: T) -> Self
pub fn set_entity<T>(self, v: T) -> Self
Sourcepub fn set_or_clear_entity<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_entity<T>(self, v: Option<T>) -> Self
Sourcepub fn set_category_entities<T, V>(self, v: T) -> Self
pub fn set_category_entities<T, V>(self, v: T) -> Self
Sets the value of category_entities.
§Example
ⓘ
use google_cloud_videointelligence_v1::model::Entity;
let x = LabelAnnotation::new()
.set_category_entities([
Entity::default()/* use setters */,
Entity::default()/* use (different) setters */,
]);Sourcepub fn set_segments<T, V>(self, v: T) -> Self
pub fn set_segments<T, V>(self, v: T) -> Self
Sourcepub fn set_frames<T, V>(self, v: T) -> Self
pub fn set_frames<T, V>(self, v: T) -> Self
Trait Implementations§
Source§impl Clone for LabelAnnotation
impl Clone for LabelAnnotation
Source§fn clone(&self) -> LabelAnnotation
fn clone(&self) -> LabelAnnotation
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for LabelAnnotation
impl Debug for LabelAnnotation
Source§impl Default for LabelAnnotation
impl Default for LabelAnnotation
Source§fn default() -> LabelAnnotation
fn default() -> LabelAnnotation
Returns the “default value” for a type. Read more
Source§impl Message for LabelAnnotation
impl Message for LabelAnnotation
Source§impl PartialEq for LabelAnnotation
impl PartialEq for LabelAnnotation
Source§fn eq(&self, other: &LabelAnnotation) -> bool
fn eq(&self, other: &LabelAnnotation) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for LabelAnnotation
Auto Trait Implementations§
impl Freeze for LabelAnnotation
impl RefUnwindSafe for LabelAnnotation
impl Send for LabelAnnotation
impl Sync for LabelAnnotation
impl Unpin for LabelAnnotation
impl UnsafeUnpin for LabelAnnotation
impl UnwindSafe for LabelAnnotation
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