blob: 58c6c03a8f4cce7a03fc074b0fde87176b01cd21 [file] [log] [blame]
Rich Lane1ac43002013-12-03 12:56:35 -08001-- binary
204 04 # version, type
300 24 # length
412 34 56 78 # xid
500 5c 16 c7 # experimenter
600 00 00 2f # subtype
700 14 # table_id
8
900 00 # key[0].type
1000 08 # key[0].length
1100 00 00 05 # key[0].value
12
1300 01 # key[1].type
1400 0a # key[1].length
1501 23 45 67 89 ab # key[1].value
16-- python
17ofp.message.bsn_gentable_entry_delete(
18 xid=0x12345678,
19 table_id=20,
20 key=[
21 ofp.bsn_tlv.port(5),
22 ofp.bsn_tlv.mac([0x01, 0x23, 0x45, 0x67, 0x89, 0xab]),
23 ])
24-- java
25builder.setXid(0x12345678)
Andreas Wundsamd4b22692014-01-14 14:17:26 -080026 .setTableId(GenTableId.of(20))
Rich Lane1ac43002013-12-03 12:56:35 -080027 .setKey(
28 ImmutableList.<OFBsnTlv>of(
Andreas Wundsamd4b22692014-01-14 14:17:26 -080029 factory.bsnTlvs().port(OFPort.of(5)),
30 factory.bsnTlvs().mac(MacAddress.of("01:23:45:67:89:ab"))
Rich Lane1ac43002013-12-03 12:56:35 -080031 )
32 )
33-- c
34obj = of_bsn_gentable_entry_delete_new(OF_VERSION_1_3);
35of_bsn_gentable_entry_delete_xid_set(obj, 0x12345678);
36of_bsn_gentable_entry_delete_table_id_set(obj, 20);
37{
38 of_object_t *list = of_list_bsn_tlv_new(OF_VERSION_1_3);
39 {
40 of_object_t *tlv = of_bsn_tlv_port_new(OF_VERSION_1_3);
41 of_bsn_tlv_port_value_set(tlv, 5);
42 of_list_append(list, tlv);
43 of_object_delete(tlv);
44 }
45 {
46 of_mac_addr_t mac = { { 0x01, 0x23, 0x45, 0x67, 0x89, 0xab } };
47 of_object_t *tlv = of_bsn_tlv_mac_new(OF_VERSION_1_3);
48 of_bsn_tlv_mac_value_set(tlv, mac);
49 of_list_append(list, tlv);
50 of_object_delete(tlv);
51 }
52 of_bsn_gentable_entry_delete_key_set(obj, list);
53 of_object_delete(list);
54}