Struct ispm_wrapper::data::Settings

source ·
pub struct Settings {
Show 24 fields pub archives: Option<Vec<RepoPath>>, pub cache_timeout: Option<isize>, pub install_path: Option<IPathObject>, pub read_only_installation_paths: Option<Vec<IPathObject>>, pub cfg_version: Option<isize>, pub gui_bounds: Option<Rectangle>, pub gui_maximized: Option<bool>, pub powershell_path: Option<PathBuf>, pub temp_directory: Option<PathBuf>, pub multi_user: Option<bool>, pub projects_default: Option<String>, pub enable_remote_manifests: Option<bool>, pub manifest_repos: Option<Vec<IPathObject>>, pub projects: Option<Vec<IPathObject>>, pub manifests: Option<Vec<IPathObject>>, pub key_store: Option<Vec<IPathObject>>, pub ignore_legacy_platform_repo_deprecation: Option<bool>, pub proxy_settings_to_use: Option<ProxySettingTypes>, pub https_proxy: Option<String>, pub http_proxy: Option<String>, pub no_proxy: Option<String>, pub authentication_config: Option<String>, pub logfile: Option<String>, pub prefer_package_type: Option<InstallationPreference>,
}
Expand description

V3 ISPM configuration, all fields are optional so older configs that we support should also work without an issue

Fields§

§archives: Option<Vec<RepoPath>>

Package repositories that ISPM can install from. Managed by the ispm config package-repos command.

§cache_timeout: Option<isize>

The timeout of the cache

§install_path: Option<IPathObject>

Installation path. Managed by the ispm config install-dir command.

§read_only_installation_paths: Option<Vec<IPathObject>>

Installation paths that are set as read-only. Managed by the ispm config ro-install-paths command.

§cfg_version: Option<isize>

The configuration version number

§gui_bounds: Option<Rectangle>

Last saved bounds of the ISPM GUI

§gui_maximized: Option<bool>

Whether the GUI was maximized

§powershell_path: Option<PathBuf>

The path to the powershell executable

§temp_directory: Option<PathBuf>

The temporary directory used by ISPM. Managed by the ispm config temp-dir command.

§multi_user: Option<bool>

Whether this is a multi-user installation

§projects_default: Option<String>

The default projects

§enable_remote_manifests: Option<bool>

Whether remtoe manifests are enabled

§manifest_repos: Option<Vec<IPathObject>>

Platform repositories that ISPM can install from. Managed by the ispm config platform-repos command.

§projects: Option<Vec<IPathObject>>

A list of registered projects

§manifests: Option<Vec<IPathObject>>

A list of manifests

§key_store: Option<Vec<IPathObject>>

Files that store decryption keys for legacy package installation. Managed by the ispm config decryption-key-files command.

§ignore_legacy_platform_repo_deprecation: Option<bool>

Whether to ignore deprecation warnings for legacy platforms

§proxy_settings_to_use: Option<ProxySettingTypes>

Proxy settings that should be used. Managed by the ispm config proxy (--dont-use|--use-env) command and flags.

§https_proxy: Option<String>

Proxy settings that should be used for HTTPS. Managed by the ispm config proxy --https command and flags.

§http_proxy: Option<String>

Proxy settings that should be used for HTTPS. Managed by the ispm config proxy command.

§no_proxy: Option<String>

URL/IP list (comma-delimited) of resources that should not use a proxy for access.

§authentication_config: Option<String>

The path to the SIMICS authentication file. Not used for public release. Managed by the ispm config auth-file command.

§logfile: Option<String>

The current logfile

§prefer_package_type: Option<InstallationPreference>

The package type that is favored

Implementations§

source§

impl Settings

source

pub fn builder() -> SettingsBuilder<((), (), (), (), (), (), (), (), (), (), (), (), (), (), (), (), (), (), (), (), (), (), (), ())>

Create a builder for building Settings. On the builder, call .archives(...)(optional), .cache_timeout(...)(optional), .install_path(...)(optional), .read_only_installation_paths(...)(optional), .cfg_version(...)(optional), .gui_bounds(...)(optional), .gui_maximized(...)(optional), .powershell_path(...)(optional), .temp_directory(...)(optional), .multi_user(...)(optional), .projects_default(...)(optional), .enable_remote_manifests(...)(optional), .manifest_repos(...)(optional), .projects(...)(optional), .manifests(...)(optional), .key_store(...)(optional), .ignore_legacy_platform_repo_deprecation(...)(optional), .proxy_settings_to_use(...)(optional), .https_proxy(...)(optional), .http_proxy(...)(optional), .no_proxy(...)(optional), .authentication_config(...)(optional), .logfile(...)(optional), .prefer_package_type(...)(optional) to set the values of the fields. Finally, call .build() to create the instance of Settings.

source§

impl Settings

source

pub fn get() -> Result<Self>

Get the current settings from the currently set configuration file

Trait Implementations§

source§

impl Clone for Settings

source§

fn clone(&self) -> Settings

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Settings

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'de> Deserialize<'de> for Settings

source§

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 PartialEq for Settings

source§

fn eq(&self, other: &Settings) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl Eq for Settings

source§

impl StructuralPartialEq for Settings

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> CloneToUninit for T
where T: Clone,

source§

unsafe fn clone_to_uninit(&self, dst: *mut T)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dst. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T> Instrument for T

§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided [Span], returning an Instrumented wrapper. Read more
§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> IntoEither for T

source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
source§

impl<T> ToOwned for T
where T: Clone,

source§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

source§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<T> WithSubscriber for T

§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a [WithDispatch] wrapper. Read more
§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a [WithDispatch] wrapper. Read more
source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,