import { IAccessToken , IAccessTokenProvider , ITokenContext } from './interfaces' ; /**
 * Implementation of  IAccessTokenProvider that returns a
 * user-provided constant access token whenever it is requested by the clients.
  export class ConstAccessTokenProvider implements IAccessTokenProvider { param { IAccessToken } accessToken public constructor ( private readonly accessToken ) { if ( accessToken == null ) { throw new TypeError ( '`accessToken` is required' ) ; } } ; /**
     * Returns a `Promise` fulfilled with the
     *  ConstAccessTokenProvider . accessToken provided to the constructor
     * of this instance.
     *
     *  param { ITokenContext } context returns { Promise < IAccessToken > } public getToken ( context ) { return Promise . resolve ( this . accessToken ) ; } }