pub struct CapabilitiesResponse<'a> { /* private fields */ }Expand description
A builder for APT capabilities responses.
Implementations§
Source§impl CapabilitiesResponse<'_>
impl CapabilitiesResponse<'_>
Sourcepub fn single_instance(self, enabled: bool) -> Self
pub fn single_instance(self, enabled: bool) -> Self
Whether or not to advertise single-instance support.
Sourcepub fn send_config(self, enabled: bool) -> Self
pub fn send_config(self, enabled: bool) -> Self
Whether or not to advertise send-config support.
Sourcepub fn version<S: Into<String>>(self, version: S) -> Self
pub fn version<S: Into<String>>(self, version: S) -> Self
Sets the version string to advertise.
By default this is set to the apt-transport crate version, though
this can be (should be) overridden to match the transport implementation version:
ⓘ
response.version(env!("CARGO_PKG_VERSION")).send().await?;pub fn local_only(self, enabled: bool) -> Self
Sourcepub fn needs_cleanup(self, enabled: bool) -> Self
pub fn needs_cleanup(self, enabled: bool) -> Self
Whether or not to advertise needs-cleanup support.
Auto Trait Implementations§
impl<'a> Freeze for CapabilitiesResponse<'a>
impl<'a> !RefUnwindSafe for CapabilitiesResponse<'a>
impl<'a> Send for CapabilitiesResponse<'a>
impl<'a> !Sync for CapabilitiesResponse<'a>
impl<'a> Unpin for CapabilitiesResponse<'a>
impl<'a> !UnwindSafe for CapabilitiesResponse<'a>
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