@startuml
autonumber
participant "xxxDB\n:xxxDB" as XDB
participant "//<color #red>extended by xxxDB//\n:DataHandler" as DH
participant "runner\n:ScriptRunner" as SR
database "Database" as DB

note over XDB : The "xxxDB" class represents\nall the Database classes because the \ndatabase handler is always the same.
[o-> XDB : methodRelatedWithQuery()
note left XDB : The method "methodRelatedWithQuery()" \nrepresents all the methods that interact\nwith the database.
activate XDB
XDB -> DH : scriptRunner()
activate DH
DH -> DH : openConnection()
DH -> SR** : runner = new ScriptRunner(connection)
DH -> SR : runScript(script)
activate SR
SR -> SR : runScript(script)
SR -> DB : execCommand()
activate DB
SR -> DB : close()
SR -> DB : rollback()
deactivate DB
deactivate SR
DH -> DH : closeAll()
deactivate DH
deactivate XDB
@enduml