Editar

Compartilhar via


MsalGuard class

Constructors

MsalGuard(MsalGuardConfiguration, MsalBroadcastService, MsalService, Location, Router)

Methods

canActivate(ActivatedRouteSnapshot, RouterStateSnapshot)
canActivateChild(ActivatedRouteSnapshot, RouterStateSnapshot)
canLoad()
getDestinationUrl(string)

Builds the absolute url for the destination page

includesCode(string)
parseUrl(string)

Parses url string to UrlTree

Constructor Details

MsalGuard(MsalGuardConfiguration, MsalBroadcastService, MsalService, Location, Router)

new MsalGuard(msalGuardConfig: MsalGuardConfiguration, msalBroadcastService: MsalBroadcastService, authService: MsalService, location: Location, router: Router)

Parameters

msalGuardConfig
MsalGuardConfiguration
msalBroadcastService
MsalBroadcastService
authService
MsalService
location

Location

router

Router

Method Details

canActivate(ActivatedRouteSnapshot, RouterStateSnapshot)

function canActivate(route: ActivatedRouteSnapshot, state: RouterStateSnapshot): Observable<boolean | UrlTree>

Parameters

route

ActivatedRouteSnapshot

state

RouterStateSnapshot

Returns

Observable<boolean | UrlTree>

canActivateChild(ActivatedRouteSnapshot, RouterStateSnapshot)

function canActivateChild(route: ActivatedRouteSnapshot, state: RouterStateSnapshot): Observable<boolean | UrlTree>

Parameters

route

ActivatedRouteSnapshot

state

RouterStateSnapshot

Returns

Observable<boolean | UrlTree>

canLoad()

function canLoad(): Observable<boolean>

Returns

Observable<boolean>

getDestinationUrl(string)

Builds the absolute url for the destination page

function getDestinationUrl(path: string): string

Parameters

path

string

Relative path of requested page

Returns

string

Full destination url

includesCode(string)

function includesCode(path: string): boolean

Parameters

path

string

Returns

boolean

parseUrl(string)

Parses url string to UrlTree

function parseUrl(url: string): UrlTree

Parameters

url

string

Returns

UrlTree