pub struct CompletionInfo {
pub values: Vec<CompletionValue>,
pub total: Option<usize>,
pub has_more: Option<bool>,
}Expand description
Information about completion suggestions
Fields§
§values: Vec<CompletionValue>List of completion values
total: Option<usize>Total number of completions available (may be more than returned)
has_more: Option<bool>Whether there are more completions available
Implementations§
Source§impl CompletionInfo
impl CompletionInfo
Sourcepub fn with_values(values: Vec<CompletionValue>) -> Self
pub fn with_values(values: Vec<CompletionValue>) -> Self
Create completion info with values
Sourcepub fn with_pagination(
values: Vec<CompletionValue>,
total: usize,
has_more: bool,
) -> Self
pub fn with_pagination( values: Vec<CompletionValue>, total: usize, has_more: bool, ) -> Self
Create completion info with pagination metadata
Trait Implementations§
Source§impl Clone for CompletionInfo
impl Clone for CompletionInfo
Source§fn clone(&self) -> CompletionInfo
fn clone(&self) -> CompletionInfo
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 CompletionInfo
impl Debug for CompletionInfo
Source§impl Default for CompletionInfo
impl Default for CompletionInfo
Source§fn default() -> CompletionInfo
fn default() -> CompletionInfo
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for CompletionInfo
impl<'de> Deserialize<'de> for CompletionInfo
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
Auto Trait Implementations§
impl Freeze for CompletionInfo
impl RefUnwindSafe for CompletionInfo
impl Send for CompletionInfo
impl Sync for CompletionInfo
impl Unpin for CompletionInfo
impl UnwindSafe for CompletionInfo
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