org.nofdev.http.oauth2.TokenContext.groovy Maven / Gradle / Ivy
package org.nofdev.http.oauth2
/**
* Created by Liutengfei on 2016/4/21 0021.
*/
@Singleton
class TokenContext {
String access_token
//单位:秒
long expires_in
long startTime
long stopTime
/**
* 是否过期
* @return true 过期,false 没有过期
*/
public boolean isExpire() {
return TokenContext.instance.getStopTime() < new Date().getTime()
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy