Skip to content

Commit e92d07b

Browse files
committed
java doc for IUserDataAccess
1 parent 4f54429 commit e92d07b

File tree

2 files changed

+26
-9
lines changed

2 files changed

+26
-9
lines changed

src/main/java/data_access/IFlashcardDataAccess.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
// use case layer
66

7-
public interface IFlashcardDataAccess {
7+
public interface IFlashcardDataAccess {
88

99
FlashcardDsRequestModel getFlashcard(Integer flashcardID);
1010

src/main/java/data_access/IUserDataAccess.java

Lines changed: 25 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,11 @@
44

55
import java.util.Collection;
66

7-
// use case layer
7+
/**
8+
* User Data Access Interface.
9+
* Application Business Rules
10+
* @author Justin Li
11+
*/
812

913
public interface IUserDataAccess {
1014

@@ -13,14 +17,27 @@ public interface IUserDataAccess {
1317
* @return the User object who has username
1418
*/
1519
CommonUserDsRequestModel getUser(String username);
16-
20+
/**
21+
* @param username the user's username
22+
* @return True if the user's username is in the database
23+
*/
1724
boolean existsByName(String username);
18-
25+
/**
26+
* @return all the User objects in the database
27+
*/
1928
Collection<CommonUserDsRequestModel> getAllUsers();
20-
21-
void saveFlashcardSetID(String username, int FlashcardSetID);
22-
23-
void deleteFlashcardSetID(String username, int FlashcardSetID);
24-
29+
/**
30+
* @param username the user's username
31+
* @param flashcardSetID the id of the flashcard set that the user would like to create.
32+
*/
33+
void saveFlashcardSetID(String username, int flashcardSetID);
34+
/**
35+
* @param username the user's username
36+
* @param flashcardSetID the id of the flashcard set that the user would like to delete.
37+
*/
38+
void deleteFlashcardSetID(String username, int flashcardSetID);
39+
/**
40+
* @param user the User object.
41+
*/
2542
void saveUser(CommonUserDsRequestModel user);
2643
}

0 commit comments

Comments
 (0)