Methods
Static
attemptResourceWithToken
- attemptResourceWithToken(resource, openTokenService, authService): Promise<void | IExternalResource>
Parameters
- resource: IExternalResource
- openTokenService: ((resource, tokenService) => Promise<any>)
- (resource, tokenService): Promise<any>
Returns Promise<any>
- authService: Service
Static
authorize
- authorize(resource, tokenStorageStrategy, clickThrough, restricted, login, getAccessToken, storeAccessToken, getStoredAccessToken): Promise<IExternalResource>
Parameters
- resource: IExternalResource
- tokenStorageStrategy: string
- clickThrough: ((resource) => Promise<any>)
- (resource): Promise<any>
Returns Promise<any>
- restricted: ((resource) => Promise<any>)
- (resource): Promise<any>
Returns Promise<any>
- login: ((resource) => Promise<any>)
- (resource): Promise<any>
Returns Promise<any>
- getAccessToken: ((resource, rejectOnError) => Promise<IAccessToken>)
- storeAccessToken: ((resource, token, tokenStorageStrategy) => Promise<any>)
- (resource, token, tokenStorageStrategy): Promise<any>
Returns Promise<any>
- getStoredAccessToken: ((resource, tokenStorageStrategy) => Promise<IAccessToken>)
Static
checkStatus
- checkStatus(response): any
Returns any
Static
createAuthorizationFailedError
- createAuthorizationFailedError(): Error
Returns Error
Static
createError
- createError(name, message): Error
Returns Error
Static
createInternalServerError
- createInternalServerError(message): Error
Returns Error
Static
createRestrictedError
- createRestrictedError(): Error
Returns Error
Static
doAuthChain
- doAuthChain(resource, openContentProviderInteraction, openTokenService, userInteractedWithContentProvider, getContentProviderInteraction, handleMovedTemporarily, showOutOfOptionsMessages): Promise<void | IExternalResource>
Parameters
- resource: IExternalResource
- openContentProviderInteraction: ((service) => any)
- (service): any
Returns any
- openTokenService: ((resource, tokenService) => Promise<any>)
- (resource, tokenService): Promise<any>
Returns Promise<any>
- userInteractedWithContentProvider: ((contentProviderInteraction) => Promise<any>)
- (contentProviderInteraction): Promise<any>
Parameters
- contentProviderInteraction: any
Returns Promise<any>
- getContentProviderInteraction: ((resource, service) => Promise<any>)
- (resource, service): Promise<any>
Returns Promise<any>
- handleMovedTemporarily: ((resource) => Promise<any>)
- (resource): Promise<any>
Returns Promise<any>
- showOutOfOptionsMessages: ((resource, service) => void)
- (resource, service): void
Returns void
Static
generateTreeNodeIds
- generateTreeNodeIds(treeNode, index?): void
Returns void
Static
getImageQuality
- getImageQuality(profile): string
Returns string
Static
getInexactLocale
- getInexactLocale(locale): string
Returns string
Static
getLocalisedValue
- getLocalisedValue(resource, locale): null | string
Parameters
- resource: any
- locale: string
Returns null | string
Static
getMediaType
- getMediaType(type): MediaType
Returns MediaType
Static
getService
- getService(resource, profile): null | Service
Parameters
- resource: any
- profile: ServiceProfile
Returns null | Service
Static
getServices
- getServices(resource, __namedParameters?): Service[]
Parameters
- resource: any
- __namedParameters: {
onlyService?: boolean;
onlyServices?: boolean;
skipParentResources?: boolean;
} = {}Optional
onlyService?: boolean
Optional
onlyServices?: boolean
Optional
skipParentResources?: boolean
Static
getTemporalComponent
- getTemporalComponent(target): null | number[]
Returns null | number[]
Static
isImageProfile
- isImageProfile(profile): boolean
Returns boolean
Static
isImageServiceType
- isImageServiceType(type): boolean
Returns boolean
Static
isLevel0ImageProfile
- isLevel0ImageProfile(profile): boolean
Returns boolean
Static
isLevel1ImageProfile
- isLevel1ImageProfile(profile): boolean
Returns boolean
Static
isLevel2ImageProfile
- isLevel2ImageProfile(profile): boolean
Returns boolean
Static
loadExternalResourceAuth09
- loadExternalResourceAuth09(resource, tokenStorageStrategy, clickThrough, restricted, login, getAccessToken, storeAccessToken, getStoredAccessToken, handleResourceResponse, options?): Promise<IExternalResource>
Parameters
- resource: IExternalResource
- tokenStorageStrategy: string
- clickThrough: ((resource) => Promise<any>)
- (resource): Promise<any>
Returns Promise<any>
- restricted: ((resource) => Promise<any>)
- (resource): Promise<any>
Returns Promise<any>
- login: ((resource) => Promise<any>)
- (resource): Promise<any>
Returns Promise<any>
- getAccessToken: ((resource, rejectOnError) => Promise<IAccessToken>)
- storeAccessToken: ((resource, token, tokenStorageStrategy) => Promise<any>)
- (resource, token, tokenStorageStrategy): Promise<any>
Returns Promise<any>
- getStoredAccessToken: ((resource, tokenStorageStrategy) => Promise<IAccessToken>)
- handleResourceResponse: ((resource) => Promise<any>)
- (resource): Promise<any>
Returns Promise<any>
Optional
options: IManifestoOptions
Static
loadExternalResourceAuth1
- loadExternalResourceAuth1(resource, openContentProviderInteraction, openTokenService, getStoredAccessToken, userInteractedWithContentProvider, getContentProviderInteraction, handleMovedTemporarily, showOutOfOptionsMessages): Promise<IExternalResource>
Parameters
- resource: IExternalResource
- openContentProviderInteraction: ((service) => any)
- (service): any
Returns any
- openTokenService: ((resource, tokenService) => Promise<void>)
- (resource, tokenService): Promise<void>
Returns Promise<void>
- getStoredAccessToken: ((resource) => Promise<null | IAccessToken>)
- userInteractedWithContentProvider: ((contentProviderInteraction) => Promise<any>)
- (contentProviderInteraction): Promise<any>
Parameters
- contentProviderInteraction: any
Returns Promise<any>
- getContentProviderInteraction: ((resource, service) => Promise<any>)
- (resource, service): Promise<any>
Returns Promise<any>
- handleMovedTemporarily: ((resource) => Promise<any>)
- (resource): Promise<any>
Returns Promise<any>
- showOutOfOptionsMessages: ((resource, service) => void)
- (resource, service): void
Returns void
Static
loadExternalResourcesAuth09
- loadExternalResourcesAuth09(resources, tokenStorageStrategy, clickThrough, restricted, login, getAccessToken, storeAccessToken, getStoredAccessToken, handleResourceResponse, options?): Promise<IExternalResource[]>
Parameters
- resources: IExternalResource[]
- tokenStorageStrategy: string
- clickThrough: ((resource) => Promise<any>)
- (resource): Promise<any>
Returns Promise<any>
- restricted: ((resource) => Promise<any>)
- (resource): Promise<any>
Returns Promise<any>
- login: ((resource) => Promise<any>)
- (resource): Promise<any>
Returns Promise<any>
- getAccessToken: ((resource, rejectOnError) => Promise<IAccessToken>)
- storeAccessToken: ((resource, token, tokenStorageStrategy) => Promise<any>)
- (resource, token, tokenStorageStrategy): Promise<any>
Returns Promise<any>
- getStoredAccessToken: ((resource, tokenStorageStrategy) => Promise<IAccessToken>)
- handleResourceResponse: ((resource) => Promise<any>)
- (resource): Promise<any>
Returns Promise<any>
Optional
options: IManifestoOptions
Static
loadExternalResourcesAuth1
- loadExternalResourcesAuth1(resources, openContentProviderInteraction, openTokenService, getStoredAccessToken, userInteractedWithContentProvider, getContentProviderInteraction, handleMovedTemporarily, showOutOfOptionsMessages): Promise<IExternalResource[]>
Parameters
- resources: IExternalResource[]
- openContentProviderInteraction: ((service) => any)
- (service): any
Returns any
- openTokenService: ((resource, tokenService) => Promise<any>)
- (resource, tokenService): Promise<any>
Returns Promise<any>
- getStoredAccessToken: ((resource) => Promise<null | IAccessToken>)
- userInteractedWithContentProvider: ((contentProviderInteraction) => Promise<any>)
- (contentProviderInteraction): Promise<any>
Parameters
- contentProviderInteraction: any
Returns Promise<any>
- getContentProviderInteraction: ((resource, service) => Promise<any>)
- (resource, service): Promise<any>
Returns Promise<any>
- handleMovedTemporarily: ((resource) => Promise<any>)
- (resource): Promise<any>
Returns Promise<any>
- showOutOfOptionsMessages: ((resource, service) => void)
- (resource, service): void
Returns void
Static
loadManifest
- loadManifest(url): Promise<any>
Returns Promise<any>
Static
normaliseType
- normaliseType(type): string
Returns string
Static
normaliseUrl
- normaliseUrl(url): string
Returns string
Static
normalisedUrlsMatch
- normalisedUrlsMatch(url1, url2): boolean
Returns boolean
Static
Private
showAuthInteraction
- showAuthInteraction(resource, tokenStorageStrategy, clickThrough, restricted, login, getAccessToken, storeAccessToken, resolve, reject): void
Parameters
- resource: IExternalResource
- tokenStorageStrategy: any
- clickThrough: any
- restricted: any
- login: any
- getAccessToken: any
- storeAccessToken: any
- resolve: any
- reject: any
Returns void
Static
traverseAndFind
- traverseAndFind(object, k, v): undefined | object
Parameters
- object: any
- k: string
- v: string
Returns undefined | object
Does a depth first traversal of an Object, returning an Object that matches provided k and v arguments