#include <ConfigAddress.h>
Public Member Functions | |
| SocketAddress | getSocketAddress (const SocketAddress::SockAddr &sockAddr, SocketAddress::SockLen sockAddrLen) |
| ConfigAddress & | setSocketAddress (const SocketAddress &socketAddress) |
| ConfigAddress & | setHost (const std::string &ipOrHostname) |
| std::string | getHost () const |
| ConfigAddress & | setPort (uint16_t port) |
| uint16_t | getPort () const |
| ConfigAddress & | setNumeric (bool numeric=true) |
| bool | getNumeric () const |
| ConfigAddress & | setNumericReverse (bool numeric=true) |
| bool | getNumericReverse () const |
| void | configurable (bool configurable=true) final |
| Public Member Functions inherited from net::config::ConfigSection | |
| template<typename T> | |
| ConfigSection (ConfigInstance *instance, T *sectionPtr, const std::string &group="Sections") | |
| ~ConfigSection () override | |
| ConfigSection (const ConfigSection &)=delete | |
| ConfigSection (ConfigSection &&)=delete | |
| ConfigSection & | operator= (const ConfigSection &)=delete |
| Public Member Functions inherited from utils::SubCommand | |
| SubCommand (const SubCommand &)=delete | |
| SubCommand (SubCommand &&)=delete | |
| SubCommand & | operator= (const SubCommand &)=delete |
| SubCommand & | operator= (SubCommand &&)=delete |
| virtual | ~SubCommand () |
| std::string | getName () const |
| std::string | version () const |
| CLI::Option * | setConfig (const std::string &defaultConfigFile) const |
| CLI::Option * | setLogFile (const std::string &defaultLogFile) const |
| CLI::Option * | setVersionFlag (const std::string &version) const |
| bool | hasParent () const |
| SubCommand * | getParent () const |
| SubCommand * | allowExtras (bool allow=true) |
| SubCommand * | required (bool required=true, bool force=true) |
| SubCommand * | required (SubCommand *subCommand, bool required=true) |
| SubCommand * | required (CLI::Option *option, bool required=true) |
| bool | getRequired () const |
| SubCommand * | needs (SubCommand *subCommand, bool needs=true) |
| SubCommand * | disabled (SubCommand *subCommand, bool disabled=true) |
| SubCommand * | setRequireCallback (const std::function< void(void)> &callback) |
| SubCommand * | finalCallback (const std::function< void()> &finalCallback) |
| std::string | configToStr () const |
| std::string | help (const CLI::App *helpApp, const CLI::AppFormatMode &mode) const |
| template<typename NewSubCommand, typename... Args> | |
| NewSubCommand * | newSubCommand (Args &&... args) |
| template<typename RequestedSubCommand> | |
| RequestedSubCommand * | getSubCommand () |
| template<typename RequestedSubCommand> | |
| RequestedSubCommand * | getSubCommand () const |
| CLI::Option * | getOption (const std::string &name) const |
| CLI::Option * | addOption (const std::string &name, const std::string &description, const std::string &typeName, const CLI::Validator &validator) const |
| template<typename ValueTypeT> | |
| CLI::Option * | addOption (const std::string &name, const std::string &description, const std::string &typeName, ValueTypeT defaultValue, const CLI::Validator &validator) const |
| template<typename ValueTypeT> | |
| CLI::Option * | addOptionVariable (const std::string &name, ValueTypeT &variable, const std::string &description, const std::string &typeName, const CLI::Validator &additionalValidator) const |
| template<typename ValueTypeT> | |
| CLI::Option * | addOptionVariable (const std::string &name, ValueTypeT &variable, const std::string &description, const std::string &typeName, ValueTypeT defaultValue, const CLI::Validator &additionalValidator) const |
| CLI::Option * | addOptionFunction (const std::string &name, const std::function< void(const std::string &)> &callback, const std::string &description, const std::string &typeName, const CLI::Validator &validator) const |
| template<typename ValueTypeT> | |
| CLI::Option * | addOptionFunction (const std::string &name, const std::function< void(const std::string &)> &callback, const std::string &description, const std::string &typeName, ValueTypeT defaultValue, const CLI::Validator &validator) const |
| CLI::Option * | addFlag (const std::string &name, const std::string &description, const std::string &typeName, const CLI::Validator &validator) const |
| template<typename ValueTypeT> | |
| CLI::Option * | addFlag (const std::string &name, const std::string &description, const std::string &typeName, ValueTypeT defaultValue, const CLI::Validator &validator) const |
| CLI::Option * | addFlagFunction (const std::string &name, const std::function< void()> &callback, const std::string &description, const std::string &typeName, const CLI::Validator &validator) const |
| CLI::Option * | addFlagFunction (const std::string &name, const std::function< void()> &callback, const std::string &description, const std::string &typeName, const std::string &defaultValue, const CLI::Validator &validator) const |
Protected Member Functions | |
| ConfigAddress (net::config::ConfigInstance *instance, const std::string &addressOptionName, const std::string &addressOptionDescription) | |
| ConfigAddress & | setIpv4Mapped (bool ipv4Mapped=true) |
| bool | getIpv4Mapped () const |
| ConfigAddress & | setAiFlags (int aiFlags) |
| int | getAiFlags () const |
| ConfigAddress & | setAiSockType (int aiSocktype) |
| int | getAiSockType () const |
| ConfigAddress & | setAiProtocol (int aiProtocol) |
| int | getAiProtocol () const |
| ConfigAddress & | setHostRequired (bool required=true) |
| ConfigAddress & | setPortRequired (bool required=true) |
| Protected Member Functions inherited from utils::SubCommand | |
| SubCommand (SubCommand *parent, std::shared_ptr< utils::AppWithPtr > appWithPtr, const std::string &group, bool final) | |
| template<typename ConcretSubCommand> | |
| SubCommand (SubCommand *parent, ConcretSubCommand *concretSubCommand, const std::string &group, bool final=true) | |
| void | parse (int argc, char *argv[]) const |
| SubCommand * | description (const std::string &description) |
| SubCommand * | footer (const std::string &footer) |
| void | removeSubCommand () |
| template<typename ValueTypeT> | |
| CLI::Option * | setDefaultValue (CLI::Option *option, const ValueTypeT &value, bool clear=true) const |
| CLI::Option * | setConfigurable (CLI::Option *option, bool configurable) const |
Private Types | |
| using | Super = ConfigAddressTypeT<SocketAddress> |
Private Member Functions | |
| SocketAddress * | init () final |
Private Attributes | |
| CLI::Option * | hostOpt = nullptr |
| CLI::Option * | portOpt = nullptr |
| CLI::Option * | numericOpt = nullptr |
| CLI::Option * | numericReverseOpt = nullptr |
| CLI::Option * | ipv4MappedOpt = nullptr |
| int | aiFlags = 0 |
| int | aiSockType = 0 |
| int | aiProtocol = 0 |
Additional Inherited Members | |
| Static Protected Member Functions inherited from utils::SubCommand | |
| static CLI::App * | getHelpTriggerApp () |
| static CLI::App * | getShowConfigTriggerApp () |
| static CLI::App * | getCommandlineTriggerApp () |
| Static Protected Attributes inherited from utils::SubCommand | |
| static std::shared_ptr< CLI::Formatter > | sectionFormatter = makeSectionFormatter() |
| static std::map< std::string, std::string > | aliases |
| static CLI::App * | helpTriggerApp = nullptr |
| static CLI::App * | showConfigTriggerApp = nullptr |
| static CLI::App * | commandlineTriggerApp = nullptr |
Definition at line 88 of file ConfigAddress.h.
|
private |
Definition at line 92 of file ConfigAddress.h.
|
protected |
Definition at line 108 of file ConfigAddress.cpp.
|
final |
Definition at line 237 of file ConfigAddress.cpp.
|
protected |
|
protected |
|
protected |
| std::string net::in6::config::ConfigAddress< ConfigAddressType >::getHost | ( | ) | const |
Definition at line 203 of file ConfigAddress.cpp.
References hostOpt.
|
protected |
Definition at line 261 of file ConfigAddress.cpp.
References ipv4MappedOpt.
| bool net::in6::config::ConfigAddress< ConfigAddressType >::getNumeric | ( | ) | const |
Definition at line 232 of file ConfigAddress.cpp.
References numericOpt.
| bool net::in6::config::ConfigAddress< ConfigAddressTypeT >::getNumericReverse | ( | ) | const |
| uint16_t net::in6::config::ConfigAddress< ConfigAddressType >::getPort | ( | ) | const |
Definition at line 218 of file ConfigAddress.cpp.
References portOpt.
| SocketAddress net::in6::config::ConfigAddress< ConfigAddressType >::getSocketAddress | ( | const SocketAddress::SockAddr & | sockAddr, |
| SocketAddress::SockLen | sockAddrLen ) |
Definition at line 168 of file ConfigAddress.cpp.
References numericReverseOpt, and net::in6::SocketAddress::SocketAddress().
|
finalprivate |
Definition at line 150 of file ConfigAddress.cpp.
References hostOpt, net::in6::SocketAddress::init(), portOpt, and net::in6::SocketAddress::SocketAddress().
|
protected |
Definition at line 266 of file ConfigAddress.cpp.
References aiFlags.
Referenced by net::in6::stream::config::ConfigSocketServer::ConfigSocketServer().
|
protected |
Definition at line 290 of file ConfigAddress.cpp.
References aiProtocol.
Referenced by net::in6::stream::config::ConfigSocketClient::ConfigSocketClient(), and net::in6::stream::config::ConfigSocketServer::ConfigSocketServer().
|
protected |
Definition at line 278 of file ConfigAddress.cpp.
References aiSockType.
Referenced by net::in6::stream::config::ConfigSocketClient::ConfigSocketClient(), and net::in6::stream::config::ConfigSocketServer::ConfigSocketServer().
| ConfigAddress< ConfigAddressType > & net::in6::config::ConfigAddress< ConfigAddressType >::setHost | ( | const std::string & | ipOrHostname | ) |
Definition at line 193 of file ConfigAddress.cpp.
References hostOpt.
Referenced by setSocketAddress().
|
protected |
Definition at line 302 of file ConfigAddress.cpp.
References hostOpt.
Referenced by net::in6::stream::config::ConfigSocketClient::ConfigSocketClient().
|
protected |
Definition at line 252 of file ConfigAddress.cpp.
References ipv4MappedOpt.
| ConfigAddress< ConfigAddressType > & net::in6::config::ConfigAddress< ConfigAddressType >::setNumeric | ( | bool | numeric = true | ) |
Definition at line 223 of file ConfigAddress.cpp.
References numericOpt.
| ConfigAddress< ConfigAddressType > & net::in6::config::ConfigAddress< ConfigAddressType >::setNumericReverse | ( | bool | numeric = true | ) |
Definition at line 243 of file ConfigAddress.cpp.
References numericReverseOpt.
| ConfigAddress< ConfigAddressType > & net::in6::config::ConfigAddress< ConfigAddressType >::setPort | ( | uint16_t | port | ) |
Definition at line 208 of file ConfigAddress.cpp.
References portOpt.
Referenced by setSocketAddress().
|
protected |
Definition at line 309 of file ConfigAddress.cpp.
References portOpt.
Referenced by net::in6::stream::config::ConfigSocketClient::ConfigSocketClient(), and net::in6::stream::config::ConfigSocketServer::ConfigSocketServer().
| ConfigAddress< ConfigAddressType > & net::in6::config::ConfigAddress< ConfigAddressType >::setSocketAddress | ( | const SocketAddress & | socketAddress | ) |
Definition at line 185 of file ConfigAddress.cpp.
References net::in6::SocketAddress::getHost(), net::in6::SocketAddress::getPort(), setHost(), and setPort().
|
private |
Definition at line 145 of file ConfigAddress.h.
Referenced by getAiFlags(), and setAiFlags().
|
private |
Definition at line 147 of file ConfigAddress.h.
Referenced by getAiProtocol(), and setAiProtocol().
|
private |
Definition at line 146 of file ConfigAddress.h.
Referenced by getAiSockType(), and setAiSockType().
|
private |
Definition at line 139 of file ConfigAddress.h.
Referenced by configurable(), getHost(), net::in6::config::ConfigAddress< net::config::ConfigAddressRemote >::getPort(), init(), setHost(), and setHostRequired().
|
private |
Definition at line 143 of file ConfigAddress.h.
Referenced by getIpv4Mapped(), and setIpv4Mapped().
|
private |
Definition at line 141 of file ConfigAddress.h.
Referenced by getNumeric(), and setNumeric().
|
private |
Definition at line 142 of file ConfigAddress.h.
Referenced by getSocketAddress(), and setNumericReverse().
|
private |
Definition at line 140 of file ConfigAddress.h.
Referenced by configurable(), getPort(), init(), setPort(), and setPortRequired().