add_route


Description:

public bool add_route (IPRoute route)

Appends a new route and associated information to the setting.

The given route is duplicated internally and is not changed by this function. If an identical route (considering attributes as well) already exists, the route is not added and the function returns false.

Note that before 1.10, this function would not consider route attributes and not add a route that has an existing route with same dest/prefix,next_hop,metric parameters.

Parameters:

this

the SettingIPConfig

route

the route to add

Returns:

true if the route was added; false if the route was already known.