#[non_exhaustive]pub struct ChunkingConfig {
pub chunk_mode: Option<ChunkMode>,
/* private fields */
}Available on crate feature
data-store-service only.Expand description
Configuration for chunking config.
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.chunk_mode: Option<ChunkMode>Additional configs that defines the behavior of the chunking.
Implementations§
Source§impl ChunkingConfig
impl ChunkingConfig
pub fn new() -> Self
Sourcepub fn set_chunk_mode<T: Into<Option<ChunkMode>>>(self, v: T) -> Self
pub fn set_chunk_mode<T: Into<Option<ChunkMode>>>(self, v: T) -> Self
Sets the value of chunk_mode.
Note that all the setters affecting chunk_mode are mutually
exclusive.
§Example
ⓘ
use google_cloud_discoveryengine_v1::model::document_processing_config::chunking_config::LayoutBasedChunkingConfig;
let x = ChunkingConfig::new().set_chunk_mode(Some(
google_cloud_discoveryengine_v1::model::document_processing_config::chunking_config::ChunkMode::LayoutBasedChunkingConfig(LayoutBasedChunkingConfig::default().into())));Sourcepub fn layout_based_chunking_config(
&self,
) -> Option<&Box<LayoutBasedChunkingConfig>>
pub fn layout_based_chunking_config( &self, ) -> Option<&Box<LayoutBasedChunkingConfig>>
The value of chunk_mode
if it holds a LayoutBasedChunkingConfig, None if the field is not set or
holds a different branch.
Sourcepub fn set_layout_based_chunking_config<T: Into<Box<LayoutBasedChunkingConfig>>>(
self,
v: T,
) -> Self
pub fn set_layout_based_chunking_config<T: Into<Box<LayoutBasedChunkingConfig>>>( self, v: T, ) -> Self
Sets the value of chunk_mode
to hold a LayoutBasedChunkingConfig.
Note that all the setters affecting chunk_mode are
mutually exclusive.
§Example
ⓘ
use google_cloud_discoveryengine_v1::model::document_processing_config::chunking_config::LayoutBasedChunkingConfig;
let x = ChunkingConfig::new().set_layout_based_chunking_config(LayoutBasedChunkingConfig::default()/* use setters */);
assert!(x.layout_based_chunking_config().is_some());Trait Implementations§
Source§impl Clone for ChunkingConfig
impl Clone for ChunkingConfig
Source§fn clone(&self) -> ChunkingConfig
fn clone(&self) -> ChunkingConfig
Returns a duplicate 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 Debug for ChunkingConfig
impl Debug for ChunkingConfig
Source§impl Default for ChunkingConfig
impl Default for ChunkingConfig
Source§fn default() -> ChunkingConfig
fn default() -> ChunkingConfig
Returns the “default value” for a type. Read more
Source§impl Message for ChunkingConfig
impl Message for ChunkingConfig
Source§impl PartialEq for ChunkingConfig
impl PartialEq for ChunkingConfig
impl StructuralPartialEq for ChunkingConfig
Auto Trait Implementations§
impl Freeze for ChunkingConfig
impl RefUnwindSafe for ChunkingConfig
impl Send for ChunkingConfig
impl Sync for ChunkingConfig
impl Unpin for ChunkingConfig
impl UnwindSafe for ChunkingConfig
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