![]() |
RTBKit
0.9
Open-source framework to create real-time ad bidding systems.
|
#include <port_range_service.h>
Public Member Functions | |
DefaultPortRangeService (unsigned rangeSize=100) | |
virtual PortRange | getRange (const std::string &name) |
virtual void | dump (std::ostream &stream=std::cerr) const |
Default implementation of the port range service. This one will assign a new block of ports each time a new service name is created.
Definition at line 101 of file port_range_service.h.
Datacratic::DefaultPortRangeService::DefaultPortRangeService | ( | unsigned | rangeSize = 100 | ) |
Ininialize the default port range service. The rangeSize parameter tells how big a chunk of ports to assign each time it is asked for one.
Definition at line 90 of file port_range_service.cc.
void Datacratic::DefaultPortRangeService::dump | ( | std::ostream & | stream = std::cerr | ) | const [virtual] |
Dump the port ranges to the given stream.
Reimplemented from Datacratic::PortRangeService.
Definition at line 110 of file port_range_service.cc.
PortRange Datacratic::DefaultPortRangeService::getRange | ( | const std::string & | name | ) | [virtual] |
Return the range of ports for the given service name, and return the range. If name is not found, then depending upon the implementation either a new range of ports will be defined for that service, or an exception will be thrown.
Implements Datacratic::PortRangeService.
Definition at line 96 of file port_range_service.cc.