token()   A
last analyzed

Complexity

Conditions 1

Size

Total Lines 2
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
c 0
b 0
f 0
dl 0
loc 2
rs 10
eloc 2
1
package unicon.matthews.security.exception;
2
3
import org.springframework.security.core.AuthenticationException;
4
5
import unicon.matthews.security.model.token.JwtToken;
6
7
/**
8
 * 
9
 * @author vladimir.stankovic
10
 *
11
 * Aug 3, 2016
12
 */
13
public class JwtExpiredTokenException extends AuthenticationException {
14
    private static final long serialVersionUID = -5959543783324224864L;
15
    
16
    private JwtToken token;
0 ignored issues
show
Best Practice introduced by
Exceptions generally should be immutable since they convey immutable data. Consider making the field token final.
Loading history...
Bug Best Practice introduced by
Fields like token in a serializable class should either be transient or serializable.
Loading history...
17
18
    public JwtExpiredTokenException(String msg) {
19
        super(msg);
20
    }
21
22
    public JwtExpiredTokenException(JwtToken token, String msg, Throwable t) {
23
        super(msg, t);
24
        this.token = token;
25
    }
26
27
    public String token() {
28
        return this.token.getToken();
29
    }
30
}
31