#[non_exhaustive]pub struct Session {
pub name: String,
pub display_name: String,
pub state: State,
pub user_pseudo_id: String,
pub turns: Vec<Turn>,
pub start_time: Option<Timestamp>,
pub end_time: Option<Timestamp>,
pub is_pinned: bool,
/* private fields */
}Expand description
External session proto definition.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.name: StringImmutable. Fully qualified name
projects/{project}/locations/global/collections/{collection}/engines/{engine}/sessions/*
display_name: StringOptional. The display name of the session.
This field is used to identify the session in the UI. By default, the display name is the first turn query text in the session.
state: StateThe state of the session.
user_pseudo_id: StringA unique identifier for tracking users.
turns: Vec<Turn>Turns.
start_time: Option<Timestamp>Output only. The time the session started.
end_time: Option<Timestamp>Output only. The time the session finished.
is_pinned: boolOptional. Whether the session is pinned, pinned session will be displayed on the top of the session list.
Implementations§
Source§impl Session
impl Session
pub fn new() -> Self
Sourcepub fn set_display_name<T: Into<String>>(self, v: T) -> Self
pub fn set_display_name<T: Into<String>>(self, v: T) -> Self
Sets the value of display_name.
Sourcepub fn set_user_pseudo_id<T: Into<String>>(self, v: T) -> Self
pub fn set_user_pseudo_id<T: Into<String>>(self, v: T) -> Self
Sets the value of user_pseudo_id.
Sourcepub fn set_start_time<T>(self, v: T) -> Self
pub fn set_start_time<T>(self, v: T) -> Self
Sets the value of start_time.
Sourcepub fn set_or_clear_start_time<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_start_time<T>(self, v: Option<T>) -> Self
Sets or clears the value of start_time.
Sourcepub fn set_end_time<T>(self, v: T) -> Self
pub fn set_end_time<T>(self, v: T) -> Self
Sets the value of end_time.
Sourcepub fn set_or_clear_end_time<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_end_time<T>(self, v: Option<T>) -> Self
Sets or clears the value of end_time.
Sourcepub fn set_is_pinned<T: Into<bool>>(self, v: T) -> Self
pub fn set_is_pinned<T: Into<bool>>(self, v: T) -> Self
Sets the value of is_pinned.