rippled
Public Types | Public Member Functions | Private Attributes | List of all members
ripple::SecretKey Class Reference

A secret key. More...

Collaboration diagram for ripple::SecretKey:
Collaboration graph
[legend]

Public Types

using const_iterator = std::uint8_t const *
 

Public Member Functions

 SecretKey ()=default
 
 SecretKey (SecretKey const &)=default
 
SecretKeyoperator= (SecretKey const &)=default
 
 ~SecretKey ()
 
 SecretKey (std::array< std::uint8_t, 32 > const &data)
 
 SecretKey (Slice const &slice)
 
std::uint8_t const * data () const
 
std::size_t size () const
 
std::string to_string () const
 Convert the secret key to a hexadecimal string. More...
 
const_iterator begin () const noexcept
 
const_iterator cbegin () const noexcept
 
const_iterator end () const noexcept
 
const_iterator cend () const noexcept
 

Private Attributes

std::uint8_t buf_ [32]
 

Detailed Description

A secret key.

Definition at line 36 of file SecretKey.h.

Member Typedef Documentation

◆ const_iterator

Definition at line 42 of file SecretKey.h.

Constructor & Destructor Documentation

◆ SecretKey() [1/4]

ripple::SecretKey::SecretKey ( )
default

◆ SecretKey() [2/4]

ripple::SecretKey::SecretKey ( SecretKey const &  )
default

◆ ~SecretKey()

ripple::SecretKey::~SecretKey ( )

Definition at line 33 of file SecretKey.cpp.

◆ SecretKey() [3/4]

ripple::SecretKey::SecretKey ( std::array< std::uint8_t, 32 > const &  data)

Definition at line 38 of file SecretKey.cpp.

◆ SecretKey() [4/4]

ripple::SecretKey::SecretKey ( Slice const &  slice)

Definition at line 43 of file SecretKey.cpp.

Member Function Documentation

◆ operator=()

SecretKey& ripple::SecretKey::operator= ( SecretKey const &  )
default

◆ data()

std::uint8_t const* ripple::SecretKey::data ( ) const

Definition at line 55 of file SecretKey.h.

◆ size()

std::size_t ripple::SecretKey::size ( ) const

Definition at line 61 of file SecretKey.h.

◆ to_string()

std::string ripple::SecretKey::to_string ( ) const

Convert the secret key to a hexadecimal string.

Note
The operator<< function is deliberately omitted to avoid accidental exposure of secret key material.

Definition at line 51 of file SecretKey.cpp.

◆ begin()

const_iterator ripple::SecretKey::begin ( ) const
noexcept

Definition at line 75 of file SecretKey.h.

◆ cbegin()

const_iterator ripple::SecretKey::cbegin ( ) const
noexcept

Definition at line 81 of file SecretKey.h.

◆ end()

const_iterator ripple::SecretKey::end ( ) const
noexcept

Definition at line 87 of file SecretKey.h.

◆ cend()

const_iterator ripple::SecretKey::cend ( ) const
noexcept

Definition at line 93 of file SecretKey.h.

Member Data Documentation

◆ buf_

std::uint8_t ripple::SecretKey::buf_[32]
private

Definition at line 39 of file SecretKey.h.