def create_interface_mulitple(self): config = ConfigInterfaces() int1 = Interface('eth1/5') int2 = Interface('eth1/8') int1.set_layer('Layer2') int2.set_layer('Layer3') # Adding interfaces to be configured config.add_interface(int1) config.add_interface(int2) return config
def create_interfcae(self): int1 = Interface('eth1/5') int1.set_admin_status('up') int1.set_layer('Layer2') int1.set_duplex('auto') int1.set_link_log('default') int1.set_mode('trunk') int1.set_speed('10G') int1.set_access_vlan('vlan-1') int1.set_trunk_log('default') int1.set_link_log('default') return int1
def create_interfcae(self): """ Create Interface object and configure the its parameters """ int1 = Interface('eth1/5') int1.set_admin_status('up') int1.set_layer('Layer2') int1.set_duplex('auto') int1.set_link_log('default') int1.set_mode('trunk') int1.set_speed('10G') int1.set_access_vlan('vlan-1') int1.set_trunk_log('default') int1.set_link_log('default') return int1