1 /*
2  * sys-emu - A system emulator for tutorials
3  * Copyright (C) 2018 - 2019 osdevelopment-info
4  *
5  * This program is free software: you can redistribute it and/or modify
6  * it under the terms of the GNU Affero General Public License as published by
7  * the Free Software Foundation, either version 3 of the License, or
8  * (at your option) any later version.
9  *
10  * This program is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13  * GNU Affero General Public License for more details.
14  *
15  * You should have received a copy of the GNU Affero General Public License
16  * along with this program.  If not, see <https://www.gnu.org/licenses/>.
17  */
18 package info.osdevelopment.sysemu
19 
20 
21 import akka.actor.ActorSystem
22 import info.osdevelopment.sysemu.config.Configuration
23 import info.osdevelopment.sysemu.rest.RestServer
24 
25 object Main {
26 
27   def main(args: Array[String]): Unit = {
28     new Main run args
29   }
30 
31 }
32 
33 class Main {
34 
35   def run(args: Array[String]): Unit = {
36     implicit val configuration = new Configuration {}
37     implicit val actorSystem = ActorSystem("emu-system", configuration.config)
38     val httpRouter = new RestServer()
39     httpRouter.start()
40   }
41 
42 }
Line Stmt Id Pos Tree Symbol Code
28 1 1002 - 1019 Apply info.osdevelopment.sysemu.Main.run new Main().run(args)
36 2 1116 - 1119 Apply info.osdevelopment.sysemu.Main.$anon.<init> new $anon()
37 5 1168 - 1215 Apply akka.actor.ActorSystem.apply akka.actor.ActorSystem.apply("emu-system", configuration.config)
37 4 1194 - 1214 Select info.osdevelopment.sysemu.config.Configuration.config configuration.config
37 3 1180 - 1192 Literal <nosymbol> "emu-system"
38 6 1237 - 1253 ApplyToImplicitArgs info.osdevelopment.sysemu.rest.RestServer.<init> new info.osdevelopment.sysemu.rest.RestServer()(actorSystem, configuration)
39 7 1258 - 1276 Apply info.osdevelopment.sysemu.rest.RestServer.start httpRouter.start()