commit | author | age
|
929228
|
1 |
/* |
U |
2 |
Calypso - Media Player Remote Control via HTTP for Raspberry Pi |
|
3 |
Copyright (C) 2021-2023 Ulrich Hilger |
|
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 |
|
7 |
published by the Free Software Foundation, either version 3 of the |
|
8 |
License, or (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 |
|
e27ab1
|
19 |
package de.uhilger.calypso; |
2f2aa7
|
20 |
|
e27ab1
|
21 |
import de.uhilger.calypso.http.Server; |
2f2aa7
|
22 |
import java.util.HashMap; |
U |
23 |
|
|
24 |
/** |
|
25 |
* |
|
26 |
* @author Ulrich Hilger |
|
27 |
*/ |
|
28 |
public class App { |
|
29 |
/** |
|
30 |
* @param args the command line arguments |
|
31 |
*/ |
|
32 |
public static void main(String[] args) { |
|
33 |
HashMap<String, String> initParams = new HashMap(); |
|
34 |
for (String arg : args) { |
|
35 |
String[] argParts = arg.split(Server.EQUAL); |
|
36 |
initParams.put(argParts[0], argParts[1]); |
|
37 |
} |
|
38 |
String conf = initParams.get(Server.CONF); |
|
39 |
AppProperties einst = new AppProperties(); |
|
40 |
einst.readFile(conf); |
|
41 |
Server server; |
|
42 |
server = new Server(); |
|
43 |
server.start(einst); |
|
44 |
} |
|
45 |
|
|
46 |
} |