Struct node_maintainer::NassunOpts
source · pub struct NassunOpts { /* private fields */ }Expand description
Build a new Nassun instance with specified options.
Implementations§
source§impl NassunOpts
impl NassunOpts
pub fn new() -> NassunOpts
sourcepub fn cache(self, cache: impl AsRef<Path>) -> NassunOpts
pub fn cache(self, cache: impl AsRef<Path>) -> NassunOpts
Cache directory to use for requests.
pub fn registry(self, registry: Url) -> NassunOpts
sourcepub fn scope_registry(self, scope: impl AsRef<str>, registry: Url) -> NassunOpts
pub fn scope_registry(self, scope: impl AsRef<str>, registry: Url) -> NassunOpts
Adds a registry to use for a specific scope.
sourcepub fn base_dir(self, base_dir: impl AsRef<Path>) -> NassunOpts
pub fn base_dir(self, base_dir: impl AsRef<Path>) -> NassunOpts
Base directory to use for resolving relative paths. Defaults to ".".
sourcepub fn default_tag(self, default_tag: impl AsRef<str>) -> NassunOpts
pub fn default_tag(self, default_tag: impl AsRef<str>) -> NassunOpts
Default tag to use when resolving package versions. Defaults to latest.
sourcepub fn memoize_metadata(self, memoize: bool) -> NassunOpts
pub fn memoize_metadata(self, memoize: bool) -> NassunOpts
Whether to memoize package metadata. This will keep any processed
packuments in memory for the lifetime of this Nassun instance.
Setting this to true may increase performance when fetching many
packages, at the cost of significant additional memory usage.
pub fn proxy(self, proxy: bool) -> NassunOpts
pub fn proxy_url(self, proxy_url: impl AsRef<str>) -> NassunOpts
pub fn no_proxy_domain(self, no_proxy_domain: impl AsRef<str>) -> NassunOpts
pub fn fetch_retries(self, fetch_retries: u32) -> NassunOpts
Trait Implementations§
source§impl Clone for NassunOpts
impl Clone for NassunOpts
source§fn clone(&self) -> NassunOpts
fn clone(&self) -> NassunOpts
Returns a copy 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 NassunOpts
impl Debug for NassunOpts
source§impl Default for NassunOpts
impl Default for NassunOpts
source§fn default() -> NassunOpts
fn default() -> NassunOpts
Returns the “default value” for a type. Read more
source§impl PartialEq for NassunOpts
impl PartialEq for NassunOpts
source§fn eq(&self, other: &NassunOpts) -> bool
fn eq(&self, other: &NassunOpts) -> bool
This method tests for
self and other values to be equal, and is used
by ==.impl Eq for NassunOpts
impl StructuralEq for NassunOpts
impl StructuralPartialEq for NassunOpts
Auto Trait Implementations§
impl RefUnwindSafe for NassunOpts
impl Send for NassunOpts
impl Sync for NassunOpts
impl Unpin for NassunOpts
impl UnwindSafe for NassunOpts
Blanket Implementations§
§impl<T> ArchivePointee for T
impl<T> ArchivePointee for T
§type ArchivedMetadata = ()
type ArchivedMetadata = ()
The archived version of the pointer metadata for this type.
§fn pointer_metadata(
_: &<T as ArchivePointee>::ArchivedMetadata
) -> <T as Pointee>::Metadata
fn pointer_metadata( _: &<T as ArchivePointee>::ArchivedMetadata ) -> <T as Pointee>::Metadata
Converts some archived metadata to the pointer metadata for itself.
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
§impl<F, W, T, D> Deserialize<With<T, W>, D> for Fwhere
W: DeserializeWith<F, T, D>,
D: Fallible + ?Sized,
F: ?Sized,
impl<F, W, T, D> Deserialize<With<T, W>, D> for Fwhere W: DeserializeWith<F, T, D>, D: Fallible + ?Sized, F: ?Sized,
§fn deserialize(
&self,
deserializer: &mut D
) -> Result<With<T, W>, <D as Fallible>::Error>
fn deserialize( &self, deserializer: &mut D ) -> Result<With<T, W>, <D as Fallible>::Error>
Deserializes using the given deserializer
§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.source§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
§impl<T> LayoutRaw for T
impl<T> LayoutRaw for T
§fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
Gets the layout of the type.