Remove old inp in routine
This commit is contained in:
@@ -192,37 +192,9 @@ def set_tank_reaction(name: str, cs: ChangeSet) -> ChangeSet:
|
||||
# LIMITING POTENTIAL value
|
||||
# ROUGHNESS CORRELATION value
|
||||
#--------------------------------------------------------------
|
||||
def inp_in_reaction(section: list[str]) -> ChangeSet:
|
||||
cs = ChangeSet()
|
||||
|
||||
for s in section:
|
||||
if s.startswith(';'):
|
||||
continue
|
||||
|
||||
tokens = s.strip().split()
|
||||
token0 = tokens[0].upper()
|
||||
if token0 == 'BULK' or token0 == 'WALL':
|
||||
pipe = tokens[1]
|
||||
key = token0.lower()
|
||||
value = tokens[2]
|
||||
cs.append(g_update_prefix | { 'type' : 'pipe_reaction', 'pipe' : pipe, key: value })
|
||||
|
||||
elif token0 == 'TANK':
|
||||
tank = tokens[1]
|
||||
value = tokens[2]
|
||||
cs.append(g_update_prefix | { 'type' : 'tank_reaction', 'tank' : tank, 'value': value })
|
||||
|
||||
else:
|
||||
line = s.upper().strip()
|
||||
for key in get_reaction_schema('').keys():
|
||||
if line.startswith(key):
|
||||
value = line.removeprefix(key).strip()
|
||||
cs.append(g_update_prefix | { 'type' : 'reaction', key : value })
|
||||
|
||||
return cs
|
||||
|
||||
|
||||
def inp_in_reaction_new(line: str) -> str:
|
||||
def inp_in_reaction(line: str) -> str:
|
||||
tokens = line.split()
|
||||
token0 = tokens[0].upper()
|
||||
if token0 == 'BULK' or token0 == 'WALL':
|
||||
|
||||
Reference in New Issue
Block a user