Restructured Util for better usability
Moved MainGame from util to client. Moved server port static from serverData to Data
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
package netwerkprog.game.server;
|
||||
|
||||
import netwerkprog.game.server.controllers.SessionController;
|
||||
import netwerkprog.game.server.data.Data;
|
||||
import netwerkprog.game.util.data.Data;
|
||||
|
||||
import java.io.DataInputStream;
|
||||
import java.io.DataOutputStream;
|
||||
|
||||
@@ -1,10 +1,9 @@
|
||||
package netwerkprog.game.server.controllers;
|
||||
|
||||
import netwerkprog.game.server.ServerClient;
|
||||
import netwerkprog.game.server.data.Data;
|
||||
import netwerkprog.game.server.data.DataParser;
|
||||
import netwerkprog.game.util.Controller;
|
||||
import netwerkprog.game.util.ServerData;
|
||||
import netwerkprog.game.util.data.Data;
|
||||
import netwerkprog.game.util.data.DataParser;
|
||||
import netwerkprog.game.util.application.Controller;
|
||||
|
||||
import java.io.DataInputStream;
|
||||
import java.io.DataOutputStream;
|
||||
@@ -46,8 +45,8 @@ public class SessionController extends Controller {
|
||||
*/
|
||||
public void listen() {
|
||||
try {
|
||||
this.serverSocket = new ServerSocket(ServerData.port());
|
||||
System.out.println("[SERVER] listening on port " + ServerData.port());
|
||||
this.serverSocket = new ServerSocket(Data.port());
|
||||
System.out.println("[SERVER] listening on port " + Data.port());
|
||||
registerClient(serverSocket.accept());
|
||||
this.serverSocket.close();
|
||||
} catch (IOException ex) {
|
||||
|
||||
@@ -1,4 +0,0 @@
|
||||
package netwerkprog.game.server.data;
|
||||
|
||||
public class Data {
|
||||
}
|
||||
@@ -1,10 +0,0 @@
|
||||
package netwerkprog.game.server.data;
|
||||
|
||||
public class DataParser {
|
||||
public DataParser() {
|
||||
}
|
||||
|
||||
public Data parse(String request) {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
@@ -1,4 +0,0 @@
|
||||
package netwerkprog.game.server.data;
|
||||
|
||||
public class Event {
|
||||
}
|
||||
Reference in New Issue
Block a user