Logo
ApraPipes 1.0
Loading...
Searching...
No Matches
apra::PropDef Struct Reference

#include <Metadata.h>

Collaboration diagram for apra::PropDef:
Collaboration graph

Public Types

enum class  Type {
  Integer , Floating , Boolean , Text ,
  Enumeration
}
 
enum class  Mutability { Static , Dynamic }
 

Public Member Functions

constexpr PropDef ()=default
 

Static Public Member Functions

static constexpr PropDef Integer (std::string_view name, int64_t default_val, int64_t min_val, int64_t max_val, std::string_view desc="", Mutability mut=Mutability::Static)
 
static constexpr PropDef Floating (std::string_view name, double default_val, double min_val, double max_val, std::string_view desc="", Mutability mut=Mutability::Static)
 
static constexpr PropDef Boolean (std::string_view name, bool default_val, std::string_view desc="", Mutability mut=Mutability::Static)
 
static constexpr PropDef Text (std::string_view name, std::string_view default_val, std::string_view desc="", std::string_view regex="", Mutability mut=Mutability::Static)
 
static constexpr PropDef Enum (std::string_view name, std::string_view default_val, std::string_view v1, std::string_view v2, std::string_view desc="", Mutability mut=Mutability::Static)
 
static constexpr PropDef Enum (std::string_view name, std::string_view default_val, std::string_view v1, std::string_view v2, std::string_view v3, std::string_view desc="", Mutability mut=Mutability::Static)
 
static constexpr PropDef Enum (std::string_view name, std::string_view default_val, std::string_view v1, std::string_view v2, std::string_view v3, std::string_view v4, std::string_view desc="", Mutability mut=Mutability::Static)
 
static constexpr PropDef DynamicInt (std::string_view name, int64_t default_val, int64_t min_val, int64_t max_val, std::string_view desc="")
 
static constexpr PropDef DynamicFloat (std::string_view name, double default_val, double min_val, double max_val, std::string_view desc="")
 
static constexpr PropDef DynamicBool (std::string_view name, bool default_val, std::string_view desc="")
 
static constexpr PropDef DynamicString (std::string_view name, std::string_view default_val, std::string_view desc="", std::string_view regex="")
 
static constexpr PropDef DynamicEnum (std::string_view name, std::string_view default_val, std::string_view v1, std::string_view v2, std::string_view desc="")
 
static constexpr PropDef DynamicEnum (std::string_view name, std::string_view default_val, std::string_view v1, std::string_view v2, std::string_view v3, std::string_view desc="")
 
static constexpr PropDef RequiredInt (std::string_view name, int64_t min_val, int64_t max_val, std::string_view desc="", Mutability mut=Mutability::Static)
 
static constexpr PropDef RequiredFloat (std::string_view name, double min_val, double max_val, std::string_view desc="", Mutability mut=Mutability::Static)
 
static constexpr PropDef RequiredString (std::string_view name, std::string_view desc="", std::string_view regex="", Mutability mut=Mutability::Static)
 
static constexpr PropDef RequiredEnum (std::string_view name, std::string_view v1, std::string_view v2, std::string_view desc="", Mutability mut=Mutability::Static)
 
static constexpr PropDef RequiredEnum (std::string_view name, std::string_view v1, std::string_view v2, std::string_view v3, std::string_view desc="", Mutability mut=Mutability::Static)
 
static constexpr PropDef RequiredEnum (std::string_view name, std::string_view v1, std::string_view v2, std::string_view v3, std::string_view v4, std::string_view desc="", Mutability mut=Mutability::Static)
 

Public Attributes

std::string_view name
 
Type type = Type::Integer
 
Mutability mutability = Mutability::Static
 
bool required = false
 
int64_t int_default = 0
 
int64_t int_min = 0
 
int64_t int_max = 0
 
double float_default = 0.0
 
double float_min = 0.0
 
double float_max = 0.0
 
bool bool_default = false
 
std::string_view string_default = ""
 
std::string_view regex_pattern = ""
 
std::array< std::string_view, MAX_ENUM_VALUESenum_values {}
 
size_t enum_value_count = 0
 
std::string_view description = ""
 
std::string_view unit = ""
 

Member Enumeration Documentation

◆ Mutability

enum class apra::PropDef::Mutability
strong
Enumerator
Static 
Dynamic 

◆ Type

enum class apra::PropDef::Type
strong
Enumerator
Integer 
Floating 
Boolean 
Text 
Enumeration 

Constructor & Destructor Documentation

◆ PropDef()

apra::PropDef::PropDef ( )
constexprdefault

Member Function Documentation

◆ Boolean()

static constexpr PropDef apra::PropDef::Boolean ( std::string_view name,
bool default_val,
std::string_view desc = "",
Mutability mut = Mutability::Static )
inlinestaticconstexpr

◆ DynamicBool()

static constexpr PropDef apra::PropDef::DynamicBool ( std::string_view name,
bool default_val,
std::string_view desc = "" )
inlinestaticconstexpr

◆ DynamicEnum() [1/2]

static constexpr PropDef apra::PropDef::DynamicEnum ( std::string_view name,
std::string_view default_val,
std::string_view v1,
std::string_view v2,
std::string_view desc = "" )
inlinestaticconstexpr
Here is the call graph for this function:

◆ DynamicEnum() [2/2]

static constexpr PropDef apra::PropDef::DynamicEnum ( std::string_view name,
std::string_view default_val,
std::string_view v1,
std::string_view v2,
std::string_view v3,
std::string_view desc = "" )
inlinestaticconstexpr
Here is the call graph for this function:

◆ DynamicFloat()

static constexpr PropDef apra::PropDef::DynamicFloat ( std::string_view name,
double default_val,
double min_val,
double max_val,
std::string_view desc = "" )
inlinestaticconstexpr

◆ DynamicInt()

static constexpr PropDef apra::PropDef::DynamicInt ( std::string_view name,
int64_t default_val,
int64_t min_val,
int64_t max_val,
std::string_view desc = "" )
inlinestaticconstexpr

◆ DynamicString()

static constexpr PropDef apra::PropDef::DynamicString ( std::string_view name,
std::string_view default_val,
std::string_view desc = "",
std::string_view regex = "" )
inlinestaticconstexpr

◆ Enum() [1/3]

static constexpr PropDef apra::PropDef::Enum ( std::string_view name,
std::string_view default_val,
std::string_view v1,
std::string_view v2,
std::string_view desc = "",
Mutability mut = Mutability::Static )
inlinestaticconstexpr
Here is the caller graph for this function:

◆ Enum() [2/3]

static constexpr PropDef apra::PropDef::Enum ( std::string_view name,
std::string_view default_val,
std::string_view v1,
std::string_view v2,
std::string_view v3,
std::string_view desc = "",
Mutability mut = Mutability::Static )
inlinestaticconstexpr

◆ Enum() [3/3]

static constexpr PropDef apra::PropDef::Enum ( std::string_view name,
std::string_view default_val,
std::string_view v1,
std::string_view v2,
std::string_view v3,
std::string_view v4,
std::string_view desc = "",
Mutability mut = Mutability::Static )
inlinestaticconstexpr

◆ Floating()

static constexpr PropDef apra::PropDef::Floating ( std::string_view name,
double default_val,
double min_val,
double max_val,
std::string_view desc = "",
Mutability mut = Mutability::Static )
inlinestaticconstexpr

◆ Integer()

static constexpr PropDef apra::PropDef::Integer ( std::string_view name,
int64_t default_val,
int64_t min_val,
int64_t max_val,
std::string_view desc = "",
Mutability mut = Mutability::Static )
inlinestaticconstexpr

◆ RequiredEnum() [1/3]

static constexpr PropDef apra::PropDef::RequiredEnum ( std::string_view name,
std::string_view v1,
std::string_view v2,
std::string_view desc = "",
Mutability mut = Mutability::Static )
inlinestaticconstexpr

◆ RequiredEnum() [2/3]

static constexpr PropDef apra::PropDef::RequiredEnum ( std::string_view name,
std::string_view v1,
std::string_view v2,
std::string_view v3,
std::string_view desc = "",
Mutability mut = Mutability::Static )
inlinestaticconstexpr

◆ RequiredEnum() [3/3]

static constexpr PropDef apra::PropDef::RequiredEnum ( std::string_view name,
std::string_view v1,
std::string_view v2,
std::string_view v3,
std::string_view v4,
std::string_view desc = "",
Mutability mut = Mutability::Static )
inlinestaticconstexpr

◆ RequiredFloat()

static constexpr PropDef apra::PropDef::RequiredFloat ( std::string_view name,
double min_val,
double max_val,
std::string_view desc = "",
Mutability mut = Mutability::Static )
inlinestaticconstexpr

◆ RequiredInt()

static constexpr PropDef apra::PropDef::RequiredInt ( std::string_view name,
int64_t min_val,
int64_t max_val,
std::string_view desc = "",
Mutability mut = Mutability::Static )
inlinestaticconstexpr

◆ RequiredString()

static constexpr PropDef apra::PropDef::RequiredString ( std::string_view name,
std::string_view desc = "",
std::string_view regex = "",
Mutability mut = Mutability::Static )
inlinestaticconstexpr

◆ Text()

static constexpr PropDef apra::PropDef::Text ( std::string_view name,
std::string_view default_val,
std::string_view desc = "",
std::string_view regex = "",
Mutability mut = Mutability::Static )
inlinestaticconstexpr

Member Data Documentation

◆ bool_default

bool apra::PropDef::bool_default = false

◆ description

std::string_view apra::PropDef::description = ""

◆ enum_value_count

size_t apra::PropDef::enum_value_count = 0

◆ enum_values

std::array<std::string_view, MAX_ENUM_VALUES> apra::PropDef::enum_values {}

◆ float_default

double apra::PropDef::float_default = 0.0

◆ float_max

double apra::PropDef::float_max = 0.0

◆ float_min

double apra::PropDef::float_min = 0.0

◆ int_default

int64_t apra::PropDef::int_default = 0

◆ int_max

int64_t apra::PropDef::int_max = 0

◆ int_min

int64_t apra::PropDef::int_min = 0

◆ mutability

Mutability apra::PropDef::mutability = Mutability::Static

◆ name

std::string_view apra::PropDef::name

◆ regex_pattern

std::string_view apra::PropDef::regex_pattern = ""

◆ required

bool apra::PropDef::required = false

◆ string_default

std::string_view apra::PropDef::string_default = ""

◆ type

Type apra::PropDef::type = Type::Integer

◆ unit

std::string_view apra::PropDef::unit = ""

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