pub enum UserMapping {
NetHsmOnlyAdmin(UserId),
SystemNetHsmBackup {
nethsm_user: SystemWideUserId,
ssh_authorized_key: AuthorizedKeyEntry,
system_user: SystemUserId,
},
SystemNetHsmMetrics {
nethsm_users: NetHsmMetricsUsers,
ssh_authorized_key: AuthorizedKeyEntry,
system_user: SystemUserId,
},
SystemNetHsmOperatorSigning {
nethsm_user: UserId,
nethsm_key_setup: SigningKeySetup,
ssh_authorized_key: AuthorizedKeyEntry,
system_user: SystemUserId,
tag: String,
},
HermeticSystemNetHsmMetrics {
nethsm_users: NetHsmMetricsUsers,
system_user: SystemUserId,
},
SystemOnlyShareDownload {
system_user: SystemUserId,
ssh_authorized_key: AuthorizedKeyEntry,
},
SystemOnlyShareUpload {
system_user: SystemUserId,
ssh_authorized_key: AuthorizedKeyEntry,
},
SystemOnlyWireGuardDownload {
system_user: SystemUserId,
ssh_authorized_key: AuthorizedKeyEntry,
},
}
Expand description
User mapping between system users and [NetHsm
] users
Variants§
NetHsmOnlyAdmin(UserId)
A NetHsm user in the Administrator role, without a system user mapped to it
SystemNetHsmBackup
A system user, with SSH access, mapped to a system-wide [NetHsm
] user in the Backup role.
Fields
nethsm_user: SystemWideUserId
The name of the [NetHsm
] user.
The SSH public key used for connecting to the system_user
.
system_user: SystemUserId
The name of the system user.
SystemNetHsmMetrics
A system user, with SSH access, mapped to a system-wide [NetHsm
] user
in the Metrics role and n
users in the Operator role with read-only access to zero or
more keys
Fields
nethsm_users: NetHsmMetricsUsers
The [NetHsm
] users in the [Metrics
][UserRole::Metrics
] and
[operator
][UserRole::Operator
] role.
The SSH public key used for connecting to the system_user
.
system_user: SystemUserId
The name of the system user.
SystemNetHsmOperatorSigning
A system user, with SSH access, mapped to a [NetHsm
] user in the
Operator role with access to a single signing key.
Signing key and NetHSM user are mapped using a tag.
Fields
nethsm_user: UserId
The name of the [NetHsm
] user.
nethsm_key_setup: SigningKeySetup
The setup of a [NetHsm
] key.
The SSH public key used for connecting to the system_user
.
system_user: SystemUserId
The name of the system user.
HermeticSystemNetHsmMetrics
A system user, without SSH access, mapped to a system-wide [NetHsm
]
user in the Metrics role and one or more NetHsm users in the Operator role with
read-only access to zero or more keys
Fields
nethsm_users: NetHsmMetricsUsers
The [NetHsm
] users in the [Metrics
][UserRole::Metrics
] and
[operator
][UserRole::Operator
] role.
system_user: SystemUserId
The name of the system user.
A system user, with SSH access, not mapped to any backend user, that is used for downloading shares of a shared secret.
A system user, with SSH access, not mapped to any backend user, that is used for uploading shares of a shared secret.
SystemOnlyWireGuardDownload
A system user, with SSH access, not mapped to any backend user, that is used for downloading the WireGuard configuration of the host.
Fields
system_user: SystemUserId
The name of the system user.
The list of SSH public keys used for connecting to the system_user
.
Implementations§
Source§impl UserMapping
impl UserMapping
Sourcepub fn get_system_user(&self) -> Option<&SystemUserId>
pub fn get_system_user(&self) -> Option<&SystemUserId>
Returns the optional system user of the mapping
§Examples
use signstar_config::{SystemUserId, UserMapping};
let mapping = UserMapping::SystemOnlyShareDownload {
system_user: "user1".parse()?,
ssh_authorized_key: "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIH3NyNfSqtDxdnWwSVzulZi0k7Lyjw3vBEG+U8y6KsuW user@host".parse()?,
};
assert_eq!(mapping.get_system_user(), Some(&SystemUserId::new("user1".to_string())?));
let mapping = UserMapping::NetHsmOnlyAdmin("user1".parse()?);
assert_eq!(mapping.get_system_user(), None);
Sourcepub fn get_nethsm_users(&self) -> Vec<UserId>
pub fn get_nethsm_users(&self) -> Vec<UserId>
Returns the NetHsm users of the mapping
§Examples
use nethsm::UserId;
use signstar_config::UserMapping;
let mapping = UserMapping::SystemOnlyShareDownload {
system_user: "user1".parse()?,
ssh_authorized_key: "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIH3NyNfSqtDxdnWwSVzulZi0k7Lyjw3vBEG+U8y6KsuW user@host".parse()?,
};
assert!(mapping.get_nethsm_users().is_empty());
let mapping = UserMapping::NetHsmOnlyAdmin("user1".parse()?);
assert_eq!(mapping.get_nethsm_users(), vec![UserId::new("user1".to_string())?]);
Sourcepub fn get_nethsm_users_and_roles(&self) -> Vec<(UserId, UserRole)>
pub fn get_nethsm_users_and_roles(&self) -> Vec<(UserId, UserRole)>
Returns the list of all tracked [UserId
]s and their respective [UserRole
]s.
§Examples
use nethsm::{UserId, UserRole};
use signstar_config::UserMapping;
let mapping = UserMapping::SystemOnlyShareDownload {
system_user: "user1".parse()?,
ssh_authorized_key: "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIH3NyNfSqtDxdnWwSVzulZi0k7Lyjw3vBEG+U8y6KsuW user@host".parse()?,
};
assert!(mapping.get_nethsm_users_and_roles().is_empty());
let mapping = UserMapping::NetHsmOnlyAdmin("user1".parse()?);
assert_eq!(mapping.get_nethsm_users_and_roles(), vec![(UserId::new("user1".to_string())?, UserRole::Administrator)]);
Returns a list of tuples containing [UserId
], [UserRole
] and a list of tags.
§Note
Certain variants of UserMapping
such as UserMapping::SystemOnlyShareDownload
,
UserMapping::SystemOnlyShareUpload
and UserMapping::SystemOnlyWireGuardDownload
always return an empty Vec
because they do not track backend users.
§Examples
use nethsm::{CryptographicKeyContext, OpenPgpUserIdList, SigningKeySetup, UserId, UserRole};
use signstar_config::{AuthorizedKeyEntry, UserMapping};
let mapping = UserMapping::SystemNetHsmOperatorSigning {
nethsm_user: "user1".parse()?,
nethsm_key_setup: SigningKeySetup::new(
"key1".parse()?,
"Curve25519".parse()?,
vec!["EdDsaSignature".parse()?],
None,
"EdDsa".parse()?,
CryptographicKeyContext::OpenPgp{
user_ids: OpenPgpUserIdList::new(vec!["John Doe <john@example.org>".parse()?])?,
version: "v4".parse()?,
},
)?,
system_user: "ssh-user1".parse()?,
ssh_authorized_key: "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIH3NyNfSqtDxdnWwSVzulZi0k7Lyjw3vBEG+U8y6KsuW user@host".parse()?,
tag: "tag1".to_string(),
};
assert_eq!(
mapping.get_nethsm_user_role_and_tags(),
vec![(UserId::new("user1".to_string())?, UserRole::Operator, vec!["tag1".to_string()])]);
Returns the SSH authorized key of the mapping if it exists.
Returns None
if the mapping does not have an SSH authorized key.
§Examples
use std::str::FromStr;
use signstar_config::{AuthorizedKeyEntry, UserMapping};
let mapping = UserMapping::SystemOnlyShareDownload {
system_user: "user1".parse()?,
ssh_authorized_key: "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIH3NyNfSqtDxdnWwSVzulZi0k7Lyjw3vBEG+U8y6KsuW user@host".parse()?,
};
assert_eq!(mapping.get_ssh_authorized_key(), Some(&AuthorizedKeyEntry::from_str("ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIH3NyNfSqtDxdnWwSVzulZi0k7Lyjw3vBEG+U8y6KsuW user@host")?));
let mapping = UserMapping::NetHsmOnlyAdmin("user1".parse()?);
assert_eq!(mapping.get_ssh_authorized_key(), None);
Sourcepub fn get_key_ids(&self, namespace: Option<&NamespaceId>) -> Vec<KeyId>
pub fn get_key_ids(&self, namespace: Option<&NamespaceId>) -> Vec<KeyId>
Returns all used [KeyId
]s of the mapping
§Examples
use nethsm::{CryptographicKeyContext, KeyId, OpenPgpUserIdList, SigningKeySetup};
use signstar_config::{AuthorizedKeyEntry, UserMapping};
let mapping = UserMapping::SystemNetHsmOperatorSigning {
nethsm_user: "user1".parse()?,
nethsm_key_setup: SigningKeySetup::new(
"key1".parse()?,
"Curve25519".parse()?,
vec!["EdDsaSignature".parse()?],
None,
"EdDsa".parse()?,
CryptographicKeyContext::OpenPgp{
user_ids: OpenPgpUserIdList::new(vec!["John Doe <john@example.org>".parse()?])?,
version: "v4".parse()?,
},
)?,
system_user: "ssh-user1".parse()?,
ssh_authorized_key: "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIH3NyNfSqtDxdnWwSVzulZi0k7Lyjw3vBEG+U8y6KsuW user@host".parse()?,
tag: "tag1".to_string(),
};
assert_eq!(mapping.get_key_ids(None), vec![KeyId::new("key1".to_string())?]);
let mapping = UserMapping::SystemOnlyShareDownload {
system_user: "user1".parse()?,
ssh_authorized_key: "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIH3NyNfSqtDxdnWwSVzulZi0k7Lyjw3vBEG+U8y6KsuW user@host".parse()?,
};
assert_eq!(mapping.get_key_ids(None), vec![]);
Returns tags for keys and users
Tags can be filtered by namespace by providing Some
namespace
.
Providing None
implies that the context is system-wide.
§Examples
use nethsm::{CryptographicKeyContext, OpenPgpUserIdList, SigningKeySetup};
use signstar_config::UserMapping;
let mapping = UserMapping::SystemOnlyShareDownload {
system_user: "user1".parse()?,
ssh_authorized_key: "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIH3NyNfSqtDxdnWwSVzulZi0k7Lyjw3vBEG+U8y6KsuW user@host".parse()?,
};
assert!(mapping.get_tags(None).is_empty());
let mapping = UserMapping::NetHsmOnlyAdmin("user1".parse()?);
assert!(mapping.get_tags(None).is_empty());
let mapping = UserMapping::SystemNetHsmOperatorSigning{
nethsm_user: "ns1~user1".parse()?,
nethsm_key_setup: SigningKeySetup::new(
"key1".parse()?,
"Curve25519".parse()?,
vec!["EdDsaSignature".parse()?],
None,
"EdDsa".parse()?,
CryptographicKeyContext::OpenPgp{
user_ids: OpenPgpUserIdList::new(vec!["John Doe <john@example.org>".parse()?])?,
version: "4".parse()?,
})?,
system_user: "user1".parse()?,
ssh_authorized_key: "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIH3NyNfSqtDxdnWwSVzulZi0k7Lyjw3vBEG+U8y6KsuW user@host".parse()?,
tag: "tag1".to_string(),
};
assert!(mapping.get_tags(None).is_empty());
assert_eq!(mapping.get_tags(Some(&"ns1".parse()?)), vec!["tag1"]);
Sourcepub fn get_nethsm_user_key_and_tag(
&self,
filter: FilterUserKeys,
) -> Vec<(UserId, SigningKeySetup, String)>
pub fn get_nethsm_user_key_and_tag( &self, filter: FilterUserKeys, ) -> Vec<(UserId, SigningKeySetup, String)>
Returns a list of tuples of [UserId
], [SigningKeySetup
] and tag for the mapping.
Using a filter
(see FilterUserKeys
) it is possible to have only a subset of the
available tuples be returned:
FilterUserKeys::All
: Returns all available tuples.FilterUserKeys::Namespaced
: Returns tuples that match [UserId
]s with a namespace.FilterUserKeys::Namespace
: Returns tuples that match [UserId
]s with a specific namespace.FilterUserKeys::SystemWide
: Returns tuples that match [UserId
]s without a namespace.FilterUserKeys::Namespace
: Returns tuples that match a specific tag.
§Examples
use nethsm::{CryptographicKeyContext, KeyId, OpenPgpUserIdList, SigningKeySetup, UserId};
use signstar_config::{FilterUserKeys, UserMapping};
let mapping = UserMapping::SystemNetHsmOperatorSigning {
nethsm_user: "user1".parse()?,
nethsm_key_setup: SigningKeySetup::new(
"key1".parse()?,
"Curve25519".parse()?,
vec!["EdDsaSignature".parse()?],
None,
"EdDsa".parse()?,
CryptographicKeyContext::OpenPgp{
user_ids: OpenPgpUserIdList::new(vec!["John Doe <john@example.org>".parse()?])?,
version: "v4".parse()?,
},
)?,
system_user: "ssh-user1".parse()?,
ssh_authorized_key: "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIH3NyNfSqtDxdnWwSVzulZi0k7Lyjw3vBEG+U8y6KsuW user@host".parse()?,
tag: "tag1".to_string(),
};
assert_eq!(
mapping.get_nethsm_user_key_and_tag(FilterUserKeys::All),
vec![(
UserId::new("user1".to_string())?,
SigningKeySetup::new(
"key1".parse()?,
"Curve25519".parse()?,
vec!["EdDsaSignature".parse()?],
None,
"EdDsa".parse()?,
CryptographicKeyContext::OpenPgp{
user_ids: OpenPgpUserIdList::new(vec!["John Doe <john@example.org>".parse()?])?,
version: "v4".parse()?,
},
)?,
"tag1".to_string(),
)]
);
assert_eq!(mapping.get_nethsm_user_key_and_tag(FilterUserKeys::Namespace("test".parse()?)), vec![]);
assert_eq!(mapping.get_nethsm_user_key_and_tag(FilterUserKeys::Tag("tag2".parse()?)), vec![]);
let mapping = UserMapping::SystemOnlyShareDownload {
system_user: "user1".parse()?,
ssh_authorized_key: "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIH3NyNfSqtDxdnWwSVzulZi0k7Lyjw3vBEG+U8y6KsuW user@host".parse()?,
};
assert_eq!(mapping.get_nethsm_user_key_and_tag(FilterUserKeys::All), vec![]);
Sourcepub fn get_namespaces(&self) -> Vec<NamespaceId>
pub fn get_namespaces(&self) -> Vec<NamespaceId>
Returns all [NetHsm
][nethsm::NetHsm
] namespaces of the mapping
§Examples
use nethsm::{CryptographicKeyContext, OpenPgpUserIdList, SigningKeySetup};
use signstar_config::UserMapping;
let mapping = UserMapping::SystemOnlyShareDownload {
system_user: "user1".parse()?,
ssh_authorized_key: "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIH3NyNfSqtDxdnWwSVzulZi0k7Lyjw3vBEG+U8y6KsuW user@host".parse()?,
};
assert!(mapping.get_namespaces().is_empty());
let mapping = UserMapping::NetHsmOnlyAdmin("user1".parse()?);
assert!(mapping.get_namespaces().is_empty());
let mapping = UserMapping::SystemNetHsmOperatorSigning{
nethsm_user: "ns1~user1".parse()?,
nethsm_key_setup: SigningKeySetup::new(
"key1".parse()?,
"Curve25519".parse()?,
vec!["EdDsaSignature".parse()?],
None,
"EdDsa".parse()?,
CryptographicKeyContext::OpenPgp{
user_ids: OpenPgpUserIdList::new(vec!["John Doe <john@example.org>".parse()?])?,
version: "4".parse()?,
})?,
system_user: "user1".parse()?,
ssh_authorized_key: "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIH3NyNfSqtDxdnWwSVzulZi0k7Lyjw3vBEG+U8y6KsuW user@host".parse()?,
tag: "tag1".to_string(),
};
assert_eq!(mapping.get_namespaces(), vec!["ns1".parse()?]);
Sourcepub fn has_system_and_nethsm_user(&self) -> bool
pub fn has_system_and_nethsm_user(&self) -> bool
Returns whether the mapping has both system and [NetHsm
] users.
Returns true
if the self
has at least one system and one [NetHsm
] user, and false
otherwise.
Trait Implementations§
Source§impl Clone for UserMapping
impl Clone for UserMapping
Source§fn clone(&self) -> UserMapping
fn clone(&self) -> UserMapping
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for UserMapping
impl Debug for UserMapping
Source§impl<'de> Deserialize<'de> for UserMapping
impl<'de> Deserialize<'de> for UserMapping
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>,
Source§impl Hash for UserMapping
impl Hash for UserMapping
Source§impl PartialEq for UserMapping
impl PartialEq for UserMapping
Source§impl Serialize for UserMapping
impl Serialize for UserMapping
impl Eq for UserMapping
impl StructuralPartialEq for UserMapping
Auto Trait Implementations§
impl Freeze for UserMapping
impl RefUnwindSafe for UserMapping
impl Send for UserMapping
impl Sync for UserMapping
impl Unpin for UserMapping
impl UnwindSafe for UserMapping
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Conv for T
impl<T> Conv for T
§impl<T> FmtForward for T
impl<T> FmtForward for T
§fn fmt_binary(self) -> FmtBinary<Self>where
Self: Binary,
fn fmt_binary(self) -> FmtBinary<Self>where
Self: Binary,
self
to use its Binary
implementation when Debug
-formatted.§fn fmt_display(self) -> FmtDisplay<Self>where
Self: Display,
fn fmt_display(self) -> FmtDisplay<Self>where
Self: Display,
self
to use its Display
implementation when
Debug
-formatted.§fn fmt_lower_exp(self) -> FmtLowerExp<Self>where
Self: LowerExp,
fn fmt_lower_exp(self) -> FmtLowerExp<Self>where
Self: LowerExp,
self
to use its LowerExp
implementation when
Debug
-formatted.§fn fmt_lower_hex(self) -> FmtLowerHex<Self>where
Self: LowerHex,
fn fmt_lower_hex(self) -> FmtLowerHex<Self>where
Self: LowerHex,
self
to use its LowerHex
implementation when
Debug
-formatted.§fn fmt_octal(self) -> FmtOctal<Self>where
Self: Octal,
fn fmt_octal(self) -> FmtOctal<Self>where
Self: Octal,
self
to use its Octal
implementation when Debug
-formatted.§fn fmt_pointer(self) -> FmtPointer<Self>where
Self: Pointer,
fn fmt_pointer(self) -> FmtPointer<Self>where
Self: Pointer,
self
to use its Pointer
implementation when
Debug
-formatted.§fn fmt_upper_exp(self) -> FmtUpperExp<Self>where
Self: UpperExp,
fn fmt_upper_exp(self) -> FmtUpperExp<Self>where
Self: UpperExp,
self
to use its UpperExp
implementation when
Debug
-formatted.§fn fmt_upper_hex(self) -> FmtUpperHex<Self>where
Self: UpperHex,
fn fmt_upper_hex(self) -> FmtUpperHex<Self>where
Self: UpperHex,
self
to use its UpperHex
implementation when
Debug
-formatted.§fn fmt_list(self) -> FmtList<Self>where
&'a Self: for<'a> IntoIterator,
fn fmt_list(self) -> FmtList<Self>where
&'a Self: for<'a> IntoIterator,
§impl<T> Pipe for Twhere
T: ?Sized,
impl<T> Pipe for Twhere
T: ?Sized,
§fn pipe<R>(self, func: impl FnOnce(Self) -> R) -> Rwhere
Self: Sized,
fn pipe<R>(self, func: impl FnOnce(Self) -> R) -> Rwhere
Self: Sized,
§fn pipe_ref<'a, R>(&'a self, func: impl FnOnce(&'a Self) -> R) -> Rwhere
R: 'a,
fn pipe_ref<'a, R>(&'a self, func: impl FnOnce(&'a Self) -> R) -> Rwhere
R: 'a,
self
and passes that borrow into the pipe function. Read more§fn pipe_ref_mut<'a, R>(&'a mut self, func: impl FnOnce(&'a mut Self) -> R) -> Rwhere
R: 'a,
fn pipe_ref_mut<'a, R>(&'a mut self, func: impl FnOnce(&'a mut Self) -> R) -> Rwhere
R: 'a,
self
and passes that borrow into the pipe function. Read more§fn pipe_borrow<'a, B, R>(&'a self, func: impl FnOnce(&'a B) -> R) -> R
fn pipe_borrow<'a, B, R>(&'a self, func: impl FnOnce(&'a B) -> R) -> R
§fn pipe_borrow_mut<'a, B, R>(
&'a mut self,
func: impl FnOnce(&'a mut B) -> R,
) -> R
fn pipe_borrow_mut<'a, B, R>( &'a mut self, func: impl FnOnce(&'a mut B) -> R, ) -> R
§fn pipe_as_ref<'a, U, R>(&'a self, func: impl FnOnce(&'a U) -> R) -> R
fn pipe_as_ref<'a, U, R>(&'a self, func: impl FnOnce(&'a U) -> R) -> R
self
, then passes self.as_ref()
into the pipe function.§fn pipe_as_mut<'a, U, R>(&'a mut self, func: impl FnOnce(&'a mut U) -> R) -> R
fn pipe_as_mut<'a, U, R>(&'a mut self, func: impl FnOnce(&'a mut U) -> R) -> R
self
, then passes self.as_mut()
into the pipe
function.§fn pipe_deref<'a, T, R>(&'a self, func: impl FnOnce(&'a T) -> R) -> R
fn pipe_deref<'a, T, R>(&'a self, func: impl FnOnce(&'a T) -> R) -> R
self
, then passes self.deref()
into the pipe function.§impl<T> Tap for T
impl<T> Tap for T
§fn tap_borrow<B>(self, func: impl FnOnce(&B)) -> Self
fn tap_borrow<B>(self, func: impl FnOnce(&B)) -> Self
Borrow<B>
of a value. Read more§fn tap_borrow_mut<B>(self, func: impl FnOnce(&mut B)) -> Self
fn tap_borrow_mut<B>(self, func: impl FnOnce(&mut B)) -> Self
BorrowMut<B>
of a value. Read more§fn tap_ref<R>(self, func: impl FnOnce(&R)) -> Self
fn tap_ref<R>(self, func: impl FnOnce(&R)) -> Self
AsRef<R>
view of a value. Read more§fn tap_ref_mut<R>(self, func: impl FnOnce(&mut R)) -> Self
fn tap_ref_mut<R>(self, func: impl FnOnce(&mut R)) -> Self
AsMut<R>
view of a value. Read more§fn tap_deref<T>(self, func: impl FnOnce(&T)) -> Self
fn tap_deref<T>(self, func: impl FnOnce(&T)) -> Self
Deref::Target
of a value. Read more§fn tap_deref_mut<T>(self, func: impl FnOnce(&mut T)) -> Self
fn tap_deref_mut<T>(self, func: impl FnOnce(&mut T)) -> Self
Deref::Target
of a value. Read more§fn tap_dbg(self, func: impl FnOnce(&Self)) -> Self
fn tap_dbg(self, func: impl FnOnce(&Self)) -> Self
.tap()
only in debug builds, and is erased in release builds.§fn tap_mut_dbg(self, func: impl FnOnce(&mut Self)) -> Self
fn tap_mut_dbg(self, func: impl FnOnce(&mut Self)) -> Self
.tap_mut()
only in debug builds, and is erased in release
builds.§fn tap_borrow_dbg<B>(self, func: impl FnOnce(&B)) -> Self
fn tap_borrow_dbg<B>(self, func: impl FnOnce(&B)) -> Self
.tap_borrow()
only in debug builds, and is erased in release
builds.§fn tap_borrow_mut_dbg<B>(self, func: impl FnOnce(&mut B)) -> Self
fn tap_borrow_mut_dbg<B>(self, func: impl FnOnce(&mut B)) -> Self
.tap_borrow_mut()
only in debug builds, and is erased in release
builds.§fn tap_ref_dbg<R>(self, func: impl FnOnce(&R)) -> Self
fn tap_ref_dbg<R>(self, func: impl FnOnce(&R)) -> Self
.tap_ref()
only in debug builds, and is erased in release
builds.§fn tap_ref_mut_dbg<R>(self, func: impl FnOnce(&mut R)) -> Self
fn tap_ref_mut_dbg<R>(self, func: impl FnOnce(&mut R)) -> Self
.tap_ref_mut()
only in debug builds, and is erased in release
builds.§fn tap_deref_dbg<T>(self, func: impl FnOnce(&T)) -> Self
fn tap_deref_dbg<T>(self, func: impl FnOnce(&T)) -> Self
.tap_deref()
only in debug builds, and is erased in release
builds.