#[non_exhaustive]pub enum SessionConfigOptionValue {
Id {
value: SessionConfigValueId,
},
Boolean {
value: bool,
},
Other(OtherSessionConfigOptionValue),
}unstable_protocol_v2 only.Expand description
The value to set for a session configuration option.
The type field acts as the discriminator in the serialized JSON form.
The type discriminator describes the shape of the value, not the option
kind. For example every option kind that picks from a list of ids
(select, radio, …) would use Id, while a future freeform
text option would get its own variant.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Id
A SessionConfigValueId string value (type: "id").
Fields
value: SessionConfigValueIdThe value ID.
Boolean
A boolean value (type: "boolean").
Other(OtherSessionConfigOptionValue)
Custom or future session configuration option value payload.
Values beginning with _ are reserved for implementation-specific
extensions. Unknown values that do not begin with _ are reserved for
future ACP variants.
Implementations§
Source§impl SessionConfigOptionValue
impl SessionConfigOptionValue
Sourcepub fn id(id: impl Into<SessionConfigValueId>) -> Self
pub fn id(id: impl Into<SessionConfigValueId>) -> Self
Create an id option value (used by select and other id-based option types).
Sourcepub fn as_id(&self) -> Option<&SessionConfigValueId>
pub fn as_id(&self) -> Option<&SessionConfigValueId>
Return the inner SessionConfigValueId if this is a
Id value.
Trait Implementations§
Source§impl Clone for SessionConfigOptionValue
impl Clone for SessionConfigOptionValue
Source§fn clone(&self) -> SessionConfigOptionValue
fn clone(&self) -> SessionConfigOptionValue
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for SessionConfigOptionValue
impl Debug for SessionConfigOptionValue
Source§impl<'de> Deserialize<'de> for SessionConfigOptionValue
impl<'de> Deserialize<'de> for SessionConfigOptionValue
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>,
impl Eq for SessionConfigOptionValue
Source§impl From<&str> for SessionConfigOptionValue
impl From<&str> for SessionConfigOptionValue
Source§impl From<SessionConfigValueId> for SessionConfigOptionValue
impl From<SessionConfigValueId> for SessionConfigOptionValue
Source§fn from(value: SessionConfigValueId) -> Self
fn from(value: SessionConfigValueId) -> Self
Source§impl From<bool> for SessionConfigOptionValue
impl From<bool> for SessionConfigOptionValue
Source§impl IntoV1 for SessionConfigOptionValue
impl IntoV1 for SessionConfigOptionValue
Source§impl JsonSchema for SessionConfigOptionValue
impl JsonSchema for SessionConfigOptionValue
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
$ref keyword. Read moreSource§impl PartialEq for SessionConfigOptionValue
impl PartialEq for SessionConfigOptionValue
Source§fn eq(&self, other: &SessionConfigOptionValue) -> bool
fn eq(&self, other: &SessionConfigOptionValue) -> bool
self and other values to be equal, and is used by ==.Source§impl Serialize for SessionConfigOptionValue
impl Serialize for SessionConfigOptionValue
impl StructuralPartialEq for SessionConfigOptionValue
Auto Trait Implementations§
impl Freeze for SessionConfigOptionValue
impl RefUnwindSafe for SessionConfigOptionValue
impl Send for SessionConfigOptionValue
impl Sync for SessionConfigOptionValue
impl Unpin for SessionConfigOptionValue
impl UnsafeUnpin for SessionConfigOptionValue
impl UnwindSafe for SessionConfigOptionValue
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.