p2p::RoutingRules::Route¶
-
class
kanzi::connect::p2p::RoutingRules
::
Route
Defines a route for a single communications element.
Public Types
-
typedef unordered_map<string, string>::iterator
AttributeIterator
-
enum
RouteDef
Values:
-
enumerator
Server
Route via Server.
-
enumerator
Direct
Route directly.
-
enumerator
Public Functions
-
Route
(RouteDef r, string link) Constructor.
- Parameters
r
: routelink
: link
-
AttributeIterator
beginAttributes
() Return beginning of attributes.
- Return
iterator to beginning of attributes
-
bool
directRouteEnabled
() const Is direct route enabled.
- Return
true if direct route enabled
-
bool
directRoutePossible
() const Determines whether route is direct and it is possible.
- Return
true if direct route is possible
-
AttributeIterator
endAttributes
() Return end of attributes iterator.
- Return
iterator to end of attributes
-
bool
equals
(const RoutingRules::Route &other) const Compares routes.
- Return
true if routes equal.
- Parameters
other
: the other route to compare this object to
-
const unordered_map<string, string> &
getAttributes
() const Retrieve attribute references.
- Return
reference to attribute container
-
const string &
getBearer
() const Retrieve bearer information.
- Return
bearer
-
shared_ptr<Endpoint>
getEndpoint
() const Getter for endpoint.
- Return
endpoint information
-
const string &
getLink
() const Getter for link information.
- Return
link information
-
bool
getReliable
() const
-
RouteDef
getRoute
() const Getter for route.
- Return
route information
-
const string &
getSubject
() const Getter for subject information.
- Return
subject information
-
bool
serverRouteEnabled
() const Routing via server enabled.
- Return
true if route via server enabled.
-
void
setAttributes
(const unordered_map<string, string> &attributes) Stores the attributes specific for the route.
- Parameters
attributes
: the attributes
-
void
setBearer
(string bearer) Stores bearer information.
- Parameters
bearer
: the bearer information
Setter for endpoint.
- Parameters
ep
: endpoint to store
-
void
setLink
(const string &link) Setter for link.
- Parameters
link
: link informaiton
-
void
setReliable
(bool reliable)
-
void
setRoute
(RouteDef route) Setter for route information.
- Parameters
route
: route
-
void
setSubject
(const string &subject) Setter for subject information.
- Parameters
subject
: subject information
-
typedef unordered_map<string, string>::iterator