public Future < AuthenticationResult > acquireTokenByDeviceCode ( final DeviceCode deviceCode , final AuthenticationCallback callback ) throws AuthenticationException { final ClientAuthentication clientAuth = new ClientAuthenticationPost ( ClientAuthenticationMethod . NONE , new ClientID ( deviceCode . getClientId ( ) ) ) ; this . validateDeviceCodeRequestInput ( deviceCode , clientAuth , deviceCode . getResource ( ) ) ; final AdalDeviceCodeAuthorizationGrant deviceCodeGrant = new AdalDeviceCodeAuthorizationGrant ( deviceCode , deviceCode . getResource ( ) ) ; return this . acquireToken ( deviceCodeGrant , clientAuth , callback ) ; }
Acquires security token from the authority using an device code previously received .