proxygen
fizz::extensions::TokenBindingContext Class Reference

#include <TokenBindingContext.h>

Public Member Functions

 ~TokenBindingContext ()=default
 
void setSupportedVersions (std::vector< TokenBindingProtocolVersion > versions)
 
const auto & getSupportedVersions () const
 
void setSupportedKeyParameters (std::vector< TokenBindingKeyParameters > keyParams)
 
const auto & getKeyParams () const
 

Private Attributes

std::vector< TokenBindingProtocolVersionsupportedVersions_
 
std::vector< TokenBindingKeyParameterssupportedKeyParams_
 

Detailed Description

Definition at line 16 of file TokenBindingContext.h.

Constructor & Destructor Documentation

fizz::extensions::TokenBindingContext::~TokenBindingContext ( )
default

Member Function Documentation

const auto& fizz::extensions::TokenBindingContext::getKeyParams ( ) const
inline

Definition at line 44 of file TokenBindingContext.h.

References supportedKeyParams_.

44  {
45  return supportedKeyParams_;
46  }
std::vector< TokenBindingKeyParameters > supportedKeyParams_
const auto& fizz::extensions::TokenBindingContext::getSupportedVersions ( ) const
inline

Definition at line 33 of file TokenBindingContext.h.

References supportedVersions_.

Referenced by fizz::test::TEST().

33  {
34  return supportedVersions_;
35  }
std::vector< TokenBindingProtocolVersion > supportedVersions_
void fizz::extensions::TokenBindingContext::setSupportedKeyParameters ( std::vector< TokenBindingKeyParameters keyParams)
inline

Set the supported key parameters in preference order.

Definition at line 40 of file TokenBindingContext.h.

References folly::gen::move, and supportedKeyParams_.

41  {
42  supportedKeyParams_ = std::move(keyParams);
43  }
constexpr detail::Map< Move > move
Definition: Base-inl.h:2567
std::vector< TokenBindingKeyParameters > supportedKeyParams_
void fizz::extensions::TokenBindingContext::setSupportedVersions ( std::vector< TokenBindingProtocolVersion versions)
inline

Set the supported Token Binding protocol versions. The input should be in descending order.

Definition at line 24 of file TokenBindingContext.h.

References folly::gen::move, and supportedVersions_.

Referenced by fizz::test::TEST().

24  {
25  if (!std::is_sorted(
26  versions.begin(),
27  versions.end(),
28  std::greater_equal<TokenBindingProtocolVersion>())) {
29  throw std::runtime_error("Protocol Versions are not in descending order");
30  }
31  supportedVersions_ = std::move(versions);
32  }
constexpr detail::Map< Move > move
Definition: Base-inl.h:2567
std::vector< TokenBindingProtocolVersion > supportedVersions_

Member Data Documentation

std::vector<TokenBindingKeyParameters> fizz::extensions::TokenBindingContext::supportedKeyParams_
private
Initial value:

Definition at line 52 of file TokenBindingContext.h.

Referenced by getKeyParams(), and setSupportedKeyParameters().

std::vector<TokenBindingProtocolVersion> fizz::extensions::TokenBindingContext::supportedVersions_
private

The documentation for this class was generated from the following file: