The neutron_taas.common.utils Module

neutron_taas.common.utils.get_list_from_ranges_str(ranges_str)

Convert the range in string format to ranges list

And yield the merged ranges in order. The argument must be a string having comma separated vlan and vlan-ranges.

get_list_from_ranges_str(“4,6,10-13,25-27,100-103”) [4, 6, 10, 11, 12, 13, 25, 26, 27, 100, 101, 102, 103]

neutron_taas.common.utils.get_ranges_str_from_list(ranges)

Convert the ranges list to string format

And yield the merged ranges in order in string format. The argument must be an iterable of pairs (start, stop).

get_ranges_str_from_list([4, 11, 12, 13, 25, 26, 27, 101, 102, 103]) “4,11-13,25-27,101-103”