pub struct TechnologySettings {
pub(crate) origins: Vec<ConfigOrigin>,
openpgp: OpenpgpSettings,
}Expand description
Settings for all supported cryptographic technologies.
Describes settings for all supported cryptographic technologies in a configuration object. May be used on a system, OS or context level.
Fields§
§origins: Vec<ConfigOrigin>§openpgp: OpenpgpSettingsImplementations§
Source§impl TechnologySettings
impl TechnologySettings
Sourcepub fn new(origins: Vec<ConfigOrigin>, openpgp: OpenpgpSettings) -> Self
pub fn new(origins: Vec<ConfigOrigin>, openpgp: OpenpgpSettings) -> Self
Creates a new TechnologySettings from an OpenpgpSettings.
Sourcepub fn origins(&self) -> &[ConfigOrigin]
pub fn origins(&self) -> &[ConfigOrigin]
Returns a reference to the list of origins that were involved in the creation of the
TechnologySettings.
Sourcepub(crate) fn from_config_with_defaults(
config: &ConfigTechnologySettings,
defaults: TechnologySettingsDefaults<'_>,
) -> Result<Self, Error>
pub(crate) fn from_config_with_defaults( config: &ConfigTechnologySettings, defaults: TechnologySettingsDefaults<'_>, ) -> Result<Self, Error>
Creates a new TechnologySettings from a ConfigTechnologySettings and defaults for
any unset fields.
§Errors
Returns an error, if a validated OpenpgpSettings cannot be created from the config and
the set of defaults.
Sourcepub fn from_yaml_str(s: &str) -> Result<Self, Error>
pub fn from_yaml_str(s: &str) -> Result<Self, Error>
Creates a new TechnologySettings from a YAML string.
Sourcepub fn openpgp_settings(&self) -> &OpenpgpSettings
pub fn openpgp_settings(&self) -> &OpenpgpSettings
Returns a reference to the tracked OpenpgpSettings.
Trait Implementations§
Source§impl Clone for TechnologySettings
impl Clone for TechnologySettings
Source§fn clone(&self) -> TechnologySettings
fn clone(&self) -> TechnologySettings
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 TechnologySettings
impl Debug for TechnologySettings
Source§impl Default for TechnologySettings
impl Default for TechnologySettings
Source§impl<'de> Deserialize<'de> for TechnologySettings
impl<'de> Deserialize<'de> for TechnologySettings
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
Source§impl Display for TechnologySettings
impl Display for TechnologySettings
Source§impl PartialEq for TechnologySettings
impl PartialEq for TechnologySettings
Source§impl Serialize for TechnologySettings
impl Serialize for TechnologySettings
Source§impl Validate for TechnologySettings
impl Validate for TechnologySettings
Source§fn validate_into(
&self,
__garde_user_ctx: &Self::Context,
__garde_path: &mut dyn FnMut() -> Path,
__garde_report: &mut Report,
)
fn validate_into( &self, __garde_user_ctx: &Self::Context, __garde_path: &mut dyn FnMut() -> Path, __garde_report: &mut Report, )
Validates
Self, aggregating all validation errors into Report.§fn validate(&self) -> Result<(), Report>where
Self::Context: Default,
fn validate(&self) -> Result<(), Report>where
Self::Context: Default,
Validates
Self, returning an Err with an aggregate of all errors if
the validation failed. Read more§fn validate_with(&self, ctx: &Self::Context) -> Result<(), Report>
fn validate_with(&self, ctx: &Self::Context) -> Result<(), Report>
Validates
Self, returning an Err with an aggregate of all errors if
the validation failed. Read moreimpl Eq for TechnologySettings
impl StructuralPartialEq for TechnologySettings
Auto Trait Implementations§
impl Freeze for TechnologySettings
impl RefUnwindSafe for TechnologySettings
impl Send for TechnologySettings
impl Sync for TechnologySettings
impl Unpin for TechnologySettings
impl UnwindSafe for TechnologySettings
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> ToCompactString for Twhere
T: Display,
impl<T> ToCompactString for Twhere
T: Display,
§fn try_to_compact_string(&self) -> Result<CompactString, ToCompactStringError>
fn try_to_compact_string(&self) -> Result<CompactString, ToCompactStringError>
Fallible version of [
ToCompactString::to_compact_string()] Read more§fn to_compact_string(&self) -> CompactString
fn to_compact_string(&self) -> CompactString
Converts the given value to a [
CompactString]. Read more