#[non_exhaustive]pub struct DocumentClassificationConfigBuilder { /* private fields */ }Expand description
A builder for DocumentClassificationConfig.
Implementations§
source§impl DocumentClassificationConfigBuilder
impl DocumentClassificationConfigBuilder
sourcepub fn mode(self, input: DocumentClassifierMode) -> Self
pub fn mode(self, input: DocumentClassifierMode) -> Self
Classification mode indicates whether the documents are MULTI_CLASS or MULTI_LABEL.
sourcepub fn set_mode(self, input: Option<DocumentClassifierMode>) -> Self
pub fn set_mode(self, input: Option<DocumentClassifierMode>) -> Self
Classification mode indicates whether the documents are MULTI_CLASS or MULTI_LABEL.
sourcepub fn get_mode(&self) -> &Option<DocumentClassifierMode>
pub fn get_mode(&self) -> &Option<DocumentClassifierMode>
Classification mode indicates whether the documents are MULTI_CLASS or MULTI_LABEL.
sourcepub fn labels(self, input: impl Into<String>) -> Self
pub fn labels(self, input: impl Into<String>) -> Self
Appends an item to labels.
To override the contents of this collection use set_labels.
One or more labels to associate with the custom classifier.
sourcepub fn set_labels(self, input: Option<Vec<String>>) -> Self
pub fn set_labels(self, input: Option<Vec<String>>) -> Self
One or more labels to associate with the custom classifier.
sourcepub fn get_labels(&self) -> &Option<Vec<String>>
pub fn get_labels(&self) -> &Option<Vec<String>>
One or more labels to associate with the custom classifier.
sourcepub fn build(self) -> DocumentClassificationConfig
pub fn build(self) -> DocumentClassificationConfig
Consumes the builder and constructs a DocumentClassificationConfig.
Trait Implementations§
source§impl Clone for DocumentClassificationConfigBuilder
impl Clone for DocumentClassificationConfigBuilder
source§fn clone(&self) -> DocumentClassificationConfigBuilder
fn clone(&self) -> DocumentClassificationConfigBuilder
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moresource§impl Default for DocumentClassificationConfigBuilder
impl Default for DocumentClassificationConfigBuilder
source§fn default() -> DocumentClassificationConfigBuilder
fn default() -> DocumentClassificationConfigBuilder
Returns the “default value” for a type. Read more
source§impl PartialEq for DocumentClassificationConfigBuilder
impl PartialEq for DocumentClassificationConfigBuilder
source§fn eq(&self, other: &DocumentClassificationConfigBuilder) -> bool
fn eq(&self, other: &DocumentClassificationConfigBuilder) -> bool
This method tests for
self and other values to be equal, and is used
by ==.impl StructuralPartialEq for DocumentClassificationConfigBuilder
Auto Trait Implementations§
impl RefUnwindSafe for DocumentClassificationConfigBuilder
impl Send for DocumentClassificationConfigBuilder
impl Sync for DocumentClassificationConfigBuilder
impl Unpin for DocumentClassificationConfigBuilder
impl UnwindSafe for DocumentClassificationConfigBuilder
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