---
title: llarp::PeerSelectionConfig
summary: config for path hop selection 

---

# llarp::PeerSelectionConfig



config for path hop selection 


`#include <config.hpp>`

## Public Functions

|                | Name           |
| -------------- | -------------- |
| void | **[defineConfigOptions](Classes/structllarp_1_1PeerSelectionConfig.md#function-defineconfigoptions)**([ConfigDefinition](Classes/structllarp_1_1ConfigDefinition.md) & conf, const [ConfigGenParameters](Classes/structllarp_1_1ConfigGenParameters.md) & params) |
| bool | **[Acceptable](Classes/structllarp_1_1PeerSelectionConfig.md#function-acceptable)**(const std::set< [RouterContact](Classes/structllarp_1_1RouterContact.md) > & hops) const<br>return true if this set of router contacts is acceptable against this config  |

## Public Attributes

|                | Name           |
| -------------- | -------------- |
| int | **[m_UniqueHopsNetmaskSize](Classes/structllarp_1_1PeerSelectionConfig.md#variable-m-uniquehopsnetmasksize)** <br>in our hops what netmask will we use for unique ips for hops i.e.  |
| std::unordered_set< std::string > | **[m_ExcludeCountries](Classes/structllarp_1_1PeerSelectionConfig.md#variable-m-excludecountries)** <br>set of countrys to exclude from path building (2 char country code)  |

## Public Functions Documentation

### function defineConfigOptions

```cpp
void defineConfigOptions(
    ConfigDefinition & conf,
    const ConfigGenParameters & params
)
```


### function Acceptable

```cpp
bool Acceptable(
    const std::set< RouterContact > & hops
) const
```

return true if this set of router contacts is acceptable against this config 

## Public Attributes Documentation

### variable m_UniqueHopsNetmaskSize

```cpp
int m_UniqueHopsNetmaskSize;
```

in our hops what netmask will we use for unique ips for hops i.e. 

32 for every hop unique ip, 24 unique /24 per hop, etc 


### variable m_ExcludeCountries

```cpp
std::unordered_set< std::string > m_ExcludeCountries;
```

set of countrys to exclude from path building (2 char country code) 

-------------------------------

Updated on 2023-01-20 at 23:19:38 +0000