Initial
This commit is contained in:
21
StreamDesc.py
Normal file
21
StreamDesc.py
Normal file
@@ -0,0 +1,21 @@
|
||||
from dataclasses import dataclass
|
||||
|
||||
|
||||
@dataclass
|
||||
class StreamDesc:
|
||||
stream_no: int
|
||||
stream_lang: str
|
||||
stream_type: str
|
||||
stream_input_no: int
|
||||
|
||||
def __init__(self, stream_line, s_type, i_stream_in):
|
||||
out = stream_line.split("|")
|
||||
self.stream_no = int(out[0])
|
||||
if "en" == out[1]:
|
||||
self.stream_lang = "eng"
|
||||
elif "de" == out[1]:
|
||||
self.stream_lang = "ger"
|
||||
else:
|
||||
self.stream_lang = out[1]
|
||||
self.stream_type = s_type
|
||||
self.stream_input_no = i_stream_in
|
||||
Reference in New Issue
Block a user