public void validateRedirectUri(String redirectUri) {
        if (ObjectUtils.isEmpty(redirectUri) || (!redirectUri.startsWith(this.redirectUrl))) {
            throw new OAuth2Exception(ErrorType.ILLEGAL_REDIRECT_URI);
        }
    }
@Test
    public void test(){
        OAuth2Client client=new OAuth2Client();

        client.setRedirectUrl("http://hsweb.me/callback");

        client.validateRedirectUri("http://hsweb.me/callback");

        client.validateRedirectUri("http://hsweb.me/callback?a=1&n=1");

    }