package Ġcom . compiler . server . controllers Ċ Ċ import Ġcom . compiler . server . model . Project Ċ import Ġcom . compiler . server . model . bean . VersionInfo Ċ import Ġcom . compiler . server . service . Kotlin Project Executor Ċ import Ġorg . springframework . web . bind . annotation . GetMapping Ċ import Ġorg . springframework . web . bind . annotation . PostMapping Ċ import Ġorg . springframework . web . bind . annotation . RequestBody Ċ import Ġorg . springframework . web . bind . annotation . RequestMapping Ċ import Ġorg . springframework . web . bind . annotation . RestController Ċ Ċ @ RestController Ċ @ RequestMapping ( value Ġ= Ġ["/ api / compiler "]) Ċ class ĠCompiler RestController ( private Ġval Ġkotlin Project Executor : ĠKotlin Project Executor ) Ġ{ ĊĠ Ġ@ PostMapping ("/ run ") ĊĠ Ġfun Ġexecute Kotlin Project Endpoint (@ RequestBody Ġproject : ĠProject ) Ġ= Ġkotlin Project Executor . run ( project ) Ċ } Ċ Ċ @ RestController Ċ class ĠVersion RestController ( private Ġval Ġkotlin Project Executor : ĠKotlin Project Executor ) Ġ{ ĊĠ Ġ@ GetMapping ("/ versions ") ĊĠ Ġfun Ġget Kotlin Version Endpoint (): ĠList < VersionInfo > Ġ= ĠlistOf ( kotlin Project Executor . getVersion ()) Ċ }