#354 finished method javadocs

This commit is contained in:
Joseph McCarthy
2016-01-31 13:46:34 +00:00
parent 98326a1e5e
commit c2e750aca1
4 changed files with 78 additions and 3 deletions

View File

@@ -19,7 +19,7 @@ public class UserGroup {
* Add the passed {@link User} to the free user group list.
*
* @param user {@link User} to be added to the free group
* @throws IllegalArgumentException
* @throws IllegalArgumentException when user is already added to the paid group
* @see User
*/
public static void addUserToFreeGroup(final User user) throws IllegalArgumentException {
@@ -36,7 +36,7 @@ public class UserGroup {
* Add the passed {@link User} to the paid user group list.
*
* @param user {@link User} to be added to the paid group
* @throws IllegalArgumentException
* @throws IllegalArgumentException when the user is already added to the free group
* @see User
*/
public static void addUserToPaidGroup(final User user) throws IllegalArgumentException {
@@ -49,6 +49,13 @@ public class UserGroup {
}
}
/**
* Method to take a {@link User} to determine if the user is in the {@link UserGroup#paidGroup}.
*
* @param user {@link User} to check if they are in the {@link UserGroup#paidGroup}
*
* @return true if the {@link User} is in {@link UserGroup#paidGroup}
*/
public static boolean isPaid(User user) {
return paidGroup.contains(user);
}