#[non_exhaustive]pub struct LayoutParser {
pub processor_name: String,
pub max_parsing_requests_per_min: i32,
/* private fields */
}Expand description
Document AI Layout Parser 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.processor_name: StringThe full resource name of a Document AI processor or processor version.
The processor must have type LAYOUT_PARSER_PROCESSOR. If specified, the
additional_config.parse_as_scanned_pdf field must be false.
Format:
projects/{project_id}/locations/{location}/processors/{processor_id}projects/{project_id}/locations/{location}/processors/{processor_id}/processorVersions/{processor_version_id}
max_parsing_requests_per_min: i32The maximum number of requests the job is allowed to make to the Document AI processor per minute. Consult https://cloud.google.com/document-ai/quotas and the Quota page for your project to set an appropriate value here. If unspecified, a default value of 120 QPM would be used.
Implementations§
Source§impl LayoutParser
impl LayoutParser
pub fn new() -> Self
Sourcepub fn set_processor_name<T: Into<String>>(self, v: T) -> Self
pub fn set_processor_name<T: Into<String>>(self, v: T) -> Self
Sets the value of processor_name.
Sourcepub fn set_max_parsing_requests_per_min<T: Into<i32>>(self, v: T) -> Self
pub fn set_max_parsing_requests_per_min<T: Into<i32>>(self, v: T) -> Self
Sets the value of max_parsing_requests_per_min.
Trait Implementations§
Source§impl Clone for LayoutParser
impl Clone for LayoutParser
Source§fn clone(&self) -> LayoutParser
fn clone(&self) -> LayoutParser
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 Debug for LayoutParser
impl Debug for LayoutParser
Source§impl Default for LayoutParser
impl Default for LayoutParser
Source§fn default() -> LayoutParser
fn default() -> LayoutParser
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for LayoutParserwhere
LayoutParser: Default,
impl<'de> Deserialize<'de> for LayoutParserwhere
LayoutParser: Default,
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Message for LayoutParser
impl Message for LayoutParser
Source§impl PartialEq for LayoutParser
impl PartialEq for LayoutParser
Source§impl Serialize for LayoutParser
impl Serialize for LayoutParser
impl StructuralPartialEq for LayoutParser
Auto Trait Implementations§
impl Freeze for LayoutParser
impl RefUnwindSafe for LayoutParser
impl Send for LayoutParser
impl Sync for LayoutParser
impl Unpin for LayoutParser
impl UnwindSafe for LayoutParser
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