Skip to content

Commit

Permalink
permission exception
Browse files Browse the repository at this point in the history
  • Loading branch information
Maximvdw committed Mar 29, 2018
1 parent 3eea107 commit 78b60a4
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 4 deletions.
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>be.maximvdw</groupId>
<artifactId>spigotsite-api</artifactId>
<version>0.3.0-SNAPSHOT</version>
<version>0.3.2-SNAPSHOT</version>
<name>SpigotSite API</name>
<description>Spigot Site API</description>
<build>
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/be/maximvdw/spigotsite/api/SpigotSite.java
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ public final class SpigotSite {
/* Spigot Site API */
private static SpigotSiteAPI api = null;
/* Spigot Site API Version */
private static String version = "0.3.0-SNAPSHOT";
private static String version = "0.3.2-SNAPSHOT";

/**
* Get spigot site API
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
package be.maximvdw.spigotsite.api.exceptions;

/**
* PermissionException
* Created by Maxim on 29/03/2018.
*/
public class PermissionException extends Exception {
}
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
import java.util.List;

import be.maximvdw.spigotsite.api.exceptions.ConnectionFailedException;
import be.maximvdw.spigotsite.api.exceptions.PermissionException;
import be.maximvdw.spigotsite.api.forum.ProfilePost;
import be.maximvdw.spigotsite.api.user.exceptions.InvalidCredentialsException;
import be.maximvdw.spigotsite.api.user.exceptions.TwoFactorAuthenticationException;
Expand All @@ -20,7 +21,7 @@ public interface UserManager {
* @return {@link be.maximvdw.spigotsite.api.user.User}
* @throws ConnectionFailedException Connection to Spigot failed
*/
User getUserById(int userid) throws ConnectionFailedException;
User getUserById(int userid) throws ConnectionFailedException, PermissionException;

/**
* Get a list of users by their name
Expand Down Expand Up @@ -146,5 +147,5 @@ User authenticate(String username, String password, User user)
* @return list of profile posts
* @throws ConnectionFailedException
*/
List<ProfilePost> getProfilePosts(User user, User profile, int count) throws ConnectionFailedException;
List<ProfilePost> getProfilePosts(User user, User profile, int count) throws ConnectionFailedException , PermissionException;
}

0 comments on commit 78b60a4

Please sign in to comment.