pub struct Connection {
pub(crate) url: Url,
pub(crate) tls_security: ConnectionSecurity,
}
Expand description
The connection to a NetHSM device.
Contains the Url
and ConnectionSecurity
for a NetHsm
device.
Fields§
§url: Url
§tls_security: ConnectionSecurity
Implementations§
Source§impl Connection
impl Connection
Sourcepub fn new(url: Url, tls_security: ConnectionSecurity) -> Self
pub fn new(url: Url, tls_security: ConnectionSecurity) -> Self
Creates a new Connection
Sourcepub fn tls_security(&self) -> &ConnectionSecurity
pub fn tls_security(&self) -> &ConnectionSecurity
Returns a reference to the contained ConnectionSecurity
.
Trait Implementations§
Source§impl Clone for Connection
impl Clone for Connection
Source§fn clone(&self) -> Connection
fn clone(&self) -> Connection
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 Connection
impl Debug for Connection
Source§impl<'de> Deserialize<'de> for Connection
impl<'de> Deserialize<'de> for Connection
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>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Hash for Connection
impl Hash for Connection
Source§impl PartialEq for Connection
impl PartialEq for Connection
Source§impl Serialize for Connection
impl Serialize for Connection
impl Eq for Connection
impl StructuralPartialEq for Connection
Auto Trait Implementations§
impl Freeze for Connection
impl RefUnwindSafe for Connection
impl Send for Connection
impl Sync for Connection
impl Unpin for Connection
impl UnwindSafe for Connection
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