예제 #1
0
 def do_table_cam_add_entry(self, line):
     # defined in p4_px_tables.py
     (table_name, keys, action_name,
      action_data) = parse_table_cam_add_entry(line)
     p4_tables_api.table_cam_add_entry(table_name, keys, action_name,
                                       action_data)
예제 #2
0
def table_cam_add_entry(table_name, keys, action_name, action_data):
    keys = KEYS_TO_NUMERIC[table_name](keys)
    action_data = DATA_TO_NUMERIC[table_name](action_data)
    p4_tables_api.table_cam_add_entry(table_name, keys, action_name,
                                      action_data)