#[non_exhaustive]pub struct ListDocumentsRequest {
pub parent: String,
pub page_size: i32,
pub page_token: String,
pub filter: String,
/* private fields */
}Available on crate feature
documents only.Expand description
Request message for Documents.ListDocuments.
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.parent: StringRequired. The knowledge base to list all documents for.
Format: projects/<Project ID>/locations/<Location ID>/knowledgeBases/<Knowledge Base ID>.
page_size: i32The maximum number of items to return in a single page. By default 10 and at most 100.
page_token: StringThe next_page_token value returned from a previous list request.
filter: StringThe filter expression used to filter documents returned by the list method. The expression has the following syntax:
<field> <operator> <value> [AND <field> <operator> <value>] …
The following fields and operators are supported:
- knowledge_types with has(:) operator
- display_name with has(:) operator
- state with equals(=) operator
Examples:
- “knowledge_types:FAQ” matches documents with FAQ knowledge type.
- “display_name:customer” matches documents whose display name contains “customer”.
- “state=ACTIVE” matches documents with ACTIVE state.
- “knowledge_types:FAQ AND state=ACTIVE” matches all active FAQ documents.
For more information about filtering, see API Filtering.
Implementations§
Source§impl ListDocumentsRequest
impl ListDocumentsRequest
pub fn new() -> Self
Sourcepub fn set_parent<T: Into<String>>(self, v: T) -> Self
pub fn set_parent<T: Into<String>>(self, v: T) -> Self
Sourcepub fn set_page_size<T: Into<i32>>(self, v: T) -> Self
pub fn set_page_size<T: Into<i32>>(self, v: T) -> Self
Sourcepub fn set_page_token<T: Into<String>>(self, v: T) -> Self
pub fn set_page_token<T: Into<String>>(self, v: T) -> Self
Sets the value of page_token.
§Example
ⓘ
let x = ListDocumentsRequest::new().set_page_token("example");Trait Implementations§
Source§impl Clone for ListDocumentsRequest
impl Clone for ListDocumentsRequest
Source§fn clone(&self) -> ListDocumentsRequest
fn clone(&self) -> ListDocumentsRequest
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 ListDocumentsRequest
impl Debug for ListDocumentsRequest
Source§impl Default for ListDocumentsRequest
impl Default for ListDocumentsRequest
Source§fn default() -> ListDocumentsRequest
fn default() -> ListDocumentsRequest
Returns the “default value” for a type. Read more
Source§impl Message for ListDocumentsRequest
impl Message for ListDocumentsRequest
Source§impl PartialEq for ListDocumentsRequest
impl PartialEq for ListDocumentsRequest
impl StructuralPartialEq for ListDocumentsRequest
Auto Trait Implementations§
impl Freeze for ListDocumentsRequest
impl RefUnwindSafe for ListDocumentsRequest
impl Send for ListDocumentsRequest
impl Sync for ListDocumentsRequest
impl Unpin for ListDocumentsRequest
impl UnwindSafe for ListDocumentsRequest
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