-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathInfoModel.py
More file actions
29 lines (25 loc) · 779 Bytes
/
Copy pathInfoModel.py
File metadata and controls
29 lines (25 loc) · 779 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
# This Python file uses the following encoding: utf-8
# {
# 'name':[
# {
# 'action':[
# {
# 'name':'','time':'','action':'','msg':'','stacks':''
# }
# ]
# }
# ]
# }
class InfoModel:
def __init__(self, name, time, action, msg, stacks):
self.name = name
self.time = time
self.action = action
self.msg = msg
self.stacks = stacks
def parse(data):
return InfoModel(data['name'],
data['time'],
data['action'],
data['msg'],
data['stacks'])