pub struct ToolCacheBuilder { /* private fields */ }Expand description
A builder for the ToolCache struct.
This allows you to customize the ToolCache instance before creating it.
Implementations§
Source§impl ToolCacheBuilder
impl ToolCacheBuilder
Sourcepub fn tool_cache(self, path: impl Into<PathBuf>) -> Self
pub fn tool_cache(self, path: impl Into<PathBuf>) -> Self
Sets the path to the tool cache directory.
§Parameters
path: The path to use for the tool cache directory.
Sourcepub fn arch(self, arch: ToolCacheArch) -> Self
pub fn arch(self, arch: ToolCacheArch) -> Self
Sets the architecture for the tool cache.
§Parameters
arch: The architecture to use (e.g., x64, arm64).
Sourcepub fn platform(self, platform: ToolPlatform) -> Self
pub fn platform(self, platform: ToolPlatform) -> Self
Sets the platform for the tool cache.
§Parameters
platform: The platform to use (e.g., Windows, Linux, macOS).
Sourcepub fn retry_count(self, count: u8) -> Self
pub fn retry_count(self, count: u8) -> Self
Sets the number of retry attempts for cache operations.
§Parameters
count: The number of retries to attempt.
Trait Implementations§
Source§impl Clone for ToolCacheBuilder
impl Clone for ToolCacheBuilder
Source§fn clone(&self) -> ToolCacheBuilder
fn clone(&self) -> ToolCacheBuilder
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 ToolCacheBuilder
impl Debug for ToolCacheBuilder
Source§impl Default for ToolCacheBuilder
impl Default for ToolCacheBuilder
Source§fn default() -> ToolCacheBuilder
fn default() -> ToolCacheBuilder
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for ToolCacheBuilder
impl RefUnwindSafe for ToolCacheBuilder
impl Send for ToolCacheBuilder
impl Sync for ToolCacheBuilder
impl Unpin for ToolCacheBuilder
impl UnwindSafe for ToolCacheBuilder
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