#[non_exhaustive]pub struct PolicyDefinition {
pub version: String,
pub translations: BTreeMap<String, PolicyTranslation>,
}Available on crate features
client or server only.Expand description
The definition of a policy document.
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.version: StringThe version of this policy document.
translations: BTreeMap<String, PolicyTranslation>Map from language codes to details of the document in that language.
Language codes SHOULD be formatted as per Section 2.2 of RFC 5646, though some implementations may use an underscore instead of dash (for example, en_US instead of en-US).
Implementations§
Trait Implementations§
Source§impl Clone for PolicyDefinition
impl Clone for PolicyDefinition
Source§fn clone(&self) -> PolicyDefinition
fn clone(&self) -> PolicyDefinition
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 PolicyDefinition
impl Debug for PolicyDefinition
Source§impl<'de> Deserialize<'de> for PolicyDefinition
impl<'de> Deserialize<'de> for PolicyDefinition
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 PolicyDefinition
impl RefUnwindSafe for PolicyDefinition
impl Send for PolicyDefinition
impl Sync for PolicyDefinition
impl Unpin for PolicyDefinition
impl UnwindSafe for PolicyDefinition
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