from .database import *


#--------------------------------------------------------------
# [EPA2]
#   PAGE     linesperpage
#   STATUS   {NONE/YES/FULL}
#   SUMMARY  {YES/NO}
#   MESSAGES {YES/NO}
#   ENERGY   {NO/YES}
#   NODES    {NONE/ALL}
#   NODES    node1  node2 ...
#   LINKS    {NONE/ALL}
#   LINKS    link1  link2 ...
#   FILE     filename
#   variable {YES/NO}
#   variable {BELOW/ABOVE/PRECISION}  value
# [EPA3][NOT SUPPORT]
#   TRIALS   {YES/NO}
#--------------------------------------------------------------


def inp_in_report(section: list[str]) -> str:
    return ''


def inp_out_report(name: str) -> list[str]:
    lines = []
    objs = read_all(name, f"select * from report")
    for obj in objs:
        key = obj['key']
        value = obj['value']
        lines.append(f'{key} {value}')
    return lines
