Create loopback interfaces. :param count: number of interfaces created. :returns: List of created interfaces.
(cls, count)
| 262 | |
| 263 | @classmethod |
| 264 | def create_loopback_interfaces(cls, count): |
| 265 | """ |
| 266 | Create loopback interfaces. |
| 267 | |
| 268 | :param count: number of interfaces created. |
| 269 | :returns: List of created interfaces. |
| 270 | """ |
| 271 | if not hasattr(cls, "vpp"): |
| 272 | cls.lo_interfaces = [] |
| 273 | return cls.lo_interfaces |
| 274 | result = [VppLoInterface(cls) for i in range(count)] |
| 275 | for intf in result: |
| 276 | setattr(cls, intf.name, intf) |
| 277 | cls.lo_interfaces = result |
| 278 | return result |
| 279 | |
| 280 | @classmethod |
| 281 | def create_bvi_interfaces(cls, count): |