Skip to content

Commit 4adae54

Browse files
clean project to release
1 parent 2879dbb commit 4adae54

2 files changed

Lines changed: 5 additions & 57 deletions

File tree

build.gradle

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ jar {
1313

1414
repositories {
1515
jcenter()
16+
maven { url 'https://jitpack.io/' }
1617
}
1718

1819
dependencies {
@@ -25,6 +26,7 @@ dependencies {
2526
// https://mvnrepository.com/artifact/org.springframework.hateoas/spring-hateoas
2627
compile 'org.springframework.hateoas:spring-hateoas:0.24.0.RELEASE'
2728

28-
compile fileTree(dir: 'libs', include: '*.jar')
29+
// PersistenceWS Stubs
30+
compileOnly 'com.github.java-game-server:stubs:0.6.2'
2931

3032
}

src/main/java/com/apporelbotna/gameserver/persistencewsclient/DAO.java

Lines changed: 2 additions & 56 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
import com.apporelbotna.gameserver.stubs.User;
1616
import com.apporelbotna.gameserver.stubs.UserWrapper;
1717

18-
//TODO los memtodos devuelven un HttpStatus que es el code de segun si ha ido bien, mal, etc.
18+
//TODO los metodos devuelven un HttpStatus que es el code de segun si ha ido bien, mal, etc.
1919
//esto se podria hacer alguna clase que controlase los codigos que se mostraran en la applicacion
2020
//personalizados y en diferentes idiomas
2121

@@ -29,16 +29,6 @@ public DAO()
2929

3030
}
3131

32-
// public boolean isUserLoggeable(String email, String tokenString)
33-
// {
34-
// UserWrapper wrapper = new UserWrapper(new User(email), new Token(tokenString));
35-
//
36-
// ResponseEntity<?> response = restTemplate.postForEntity(SERVER_URL + "/auth", wrapper,
37-
// null);
38-
//
39-
// return (response.getStatusCode().equals(HttpStatus.OK));
40-
// }
41-
4232
public boolean isUserLoggeable(String email, String tokenString)
4333
{
4434
UserWrapper wrapper = new UserWrapper(new User(email), new
@@ -53,7 +43,7 @@ public boolean isUserLoggeable(String email, String tokenString)
5343

5444
public User validateUser(String email, String tokenString)
5545
{
56-
46+
//TODO implement
5747
return null;
5848
}
5949

@@ -120,50 +110,6 @@ public List<RankingPointsTO> getRankingPointsByGameAndUser(int gameId)
120110
return responseWS.getBody();
121111
}
122112

123-
public static void main(String[] args)
124-
{
125-
DAO dao = new DAO();
126-
127-
// Creating User
128-
// User user = new User("[email protected]", "Jan");
129-
// String password = "1234";
130-
//
131-
// System.out.println(dao.createUser(user, password));
132-
133-
// Testing log in
134-
//
135-
// String email = "[email protected]";
136-
// String password = "1234";
137-
// Token token = dao.login(email, password);
138-
// System.out.println(token);
139-
140-
// Find all games by username
141-
// List<Game> games = dao.findAllGamesByUser(new User("[email protected]", "pp"));
142-
// for (Game game : games)
143-
// {
144-
// System.out.println(game);
145-
// }
146-
147-
// TEST USER INFORMATION
148-
149-
// User userInformatiton = dao.getUserInformation("[email protected]");
150-
// System.out.println(userInformatiton);
151-
152-
// GET TIME PLAYED IN GAME
153-
// String email = "[email protected]";
154-
// int game = 1;
155-
// System.out.println(dao.gameTimePlayedByGame(email, game));
156-
157-
// List<RankingPointsTO> ranking = dao.getRankingPointsByGameAndUser(1);
158-
// for (RankingPointsTO rankingPointsTO : ranking)
159-
// {
160-
// System.out.println(rankingPointsTO);
161-
// }
162-
163-
// Auth
164-
System.out.println(
165-
dao.isUserLoggeable("[email protected]", "114e39264fd343e98e138837172a9e36"));
166113

167-
}
168114

169115
}

0 commit comments

Comments
 (0)