ipfs-chromium
Loading...
Searching...
No Matches
Public Member Functions | List of all members
ipfs::ctx::TransitoryGatewayConfig Class Reference

#include <include/ipfs_client/ctx/transitory_gateway_config.h>

Inheritance diagram for ipfs::ctx::TransitoryGatewayConfig:
Inheritance graph
[legend]
Collaboration diagram for ipfs::ctx::TransitoryGatewayConfig:
Collaboration graph
[legend]

Public Member Functions

std::optional< GatewaySpecGetGateway (std::size_t index) const override
 
unsigned GetGatewayRate (std::string_view) override
 
void SetGatewayRate (std::string_view, unsigned) override
 
void AddGateway (std::string_view, unsigned) override
 
unsigned RoutingApiDiscoveryDefaultRate () const override
 
bool RoutingApiDiscoveryOfUnencryptedGateways () const override
 
int GetTypeAffinity (std::string_view url_prefix, gw::GatewayRequestType) const override
 
void SetTypeAffinity (std::string_view url_prefix, gw::GatewayRequestType, int) override
 
 TransitoryGatewayConfig ()
 

Detailed Description

Takes the place of a configuration, but it's not persisted

Constructor & Destructor Documentation

◆ TransitoryGatewayConfig()

ipfs::ctx::TransitoryGatewayConfig::TransitoryGatewayConfig ( )

Loads gateways from IPFS_GATEWAY environment or a static list

Member Function Documentation

◆ AddGateway()

void ipfs::ctx::TransitoryGatewayConfig::AddGateway ( std::string_view  ,
unsigned   
)
overridevirtual

◆ GetGateway()

std::optional< GatewaySpec > ipfs::ctx::TransitoryGatewayConfig::GetGateway ( std::size_t  index) const
overridevirtual

Position-based access (indexing)

Parameters
indexThe 0-based index of the gateway in question
Returns
The spec for the gateway iff index < count of gateways, nullopt otherwise

Implements ipfs::ctx::GatewayConfig.

◆ GetGatewayRate()

unsigned ipfs::ctx::TransitoryGatewayConfig::GetGatewayRate ( std::string_view  )
overridevirtual

◆ GetTypeAffinity()

int ipfs::ctx::TransitoryGatewayConfig::GetTypeAffinity ( std::string_view  url_prefix,
gw::GatewayRequestType   
) const
overridevirtual

◆ RoutingApiDiscoveryDefaultRate()

unsigned ipfs::ctx::TransitoryGatewayConfig::RoutingApiDiscoveryDefaultRate ( ) const
overridevirtual

◆ RoutingApiDiscoveryOfUnencryptedGateways()

bool ipfs::ctx::TransitoryGatewayConfig::RoutingApiDiscoveryOfUnencryptedGateways ( ) const
overridevirtual

◆ SetGatewayRate()

void ipfs::ctx::TransitoryGatewayConfig::SetGatewayRate ( std::string_view  ,
unsigned   
)
overridevirtual

◆ SetTypeAffinity()

void ipfs::ctx::TransitoryGatewayConfig::SetTypeAffinity ( std::string_view  url_prefix,
gw::GatewayRequestType  ,
int   
)
overridevirtual

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