Home Reference Source Test

Function

Static Public Summary
public

activate(runtimeProtoStubURL: URL.RuntimeURL, busPostMessage: Message.Message, configuration: ProtoStubDescriptor.ConfigurationDataList): Object

To activate this protocol stub, using the same method for all protostub.

public

assign(obj: *, keyPath: *, value: *)

public

buildURL(configuration: object, component: string, resource: string, type: string, useFallback: boolean): string

Build a full url with the runtime configuration;

public

checkAttribute(path: *): *

public

Check if the user identifier is already in the URL format, if not, convert to URL format

public

Make a COPY of the original data

public

divideEmail(email: *): *

public

divideURL(url: URL.URL): divideURL

Divide an url in type, domain and identity

public

Check if an Object is empty

public

Generate a Global Unique ID

public

getConfigurationResources(configuration: object, component: string, resource: string): object

get information relative each component configured on runtime configuration;

public

getUserEmailFromURL(userURL: URL.URL): string

Obtains the user email that corresponds to a given URL

public
public

getUserURLFromEmail(userEmail: string): URL.URL

Obtains the user URL that corresponds to a given email

public

Check if URL is from a backend service

public

isDataObjectURL(url: *): *

public

isHypertyURL(url: *): *

public

isLegacy(url: *): boolean

public

isURL(url: *): *

public

isUserURL(url: *): *

public

parseAttributes(path: *): *

public

removePathFromURL(url: *): *

public

schemaValidation(scheme: *, descriptor: *, value: *)

public

splitObjectURL(dataObjectURL: *): *

Static Public

public activate(runtimeProtoStubURL: URL.RuntimeURL, busPostMessage: Message.Message, configuration: ProtoStubDescriptor.ConfigurationDataList): Object source

To activate this protocol stub, using the same method for all protostub.

Params:

NameTypeAttributeDescription
runtimeProtoStubURL URL.RuntimeURL

runtimeProtoSubURL

busPostMessage Message.Message

configuration

configuration ProtoStubDescriptor.ConfigurationDataList

configuration

Return:

Object

Object with name and instance of ProtoStub

public assign(obj: *, keyPath: *, value: *) source

import {assign} from 'runtime-core/src/utils/utils.js'

Params:

NameTypeAttributeDescription
obj *
keyPath *
value *

public buildURL(configuration: object, component: string, resource: string, type: string, useFallback: boolean): string source

import {buildURL} from 'runtime-core/src/utils/utils.js'

Build a full url with the runtime configuration;

Params:

NameTypeAttributeDescription
configuration object

object with all configuration

component string

string with the component to get the configuration, like, runtimeURLS, catalogueURLs, msgNodeURL, domainRegistryURL;

resource string

type of resource to get, like, catalogue, runtimeUA, protocolstub, idpProxy

type string

resource to get, like a hyperty name or protocolstub name;

useFallback boolean

if true the function will check if have a fallback url;

Return:

string

partial url to contact the resource;

public checkAttribute(path: *): * source

import {checkAttribute} from 'runtime-core/src/utils/utils.js'

Params:

NameTypeAttributeDescription
path *

Return:

*

public convertToUserURL(identifier: string): string source

import {convertToUserURL} from 'runtime-core/src/utils/utils.js'

Check if the user identifier is already in the URL format, if not, convert to URL format

Params:

NameTypeAttributeDescription
identifier string

user identifier

Return:

string

userURL the user URL

public deepClone(obj: Object): Object source

import {deepClone} from 'runtime-core/src/utils/utils.js'

Make a COPY of the original data

Params:

NameTypeAttributeDescription
obj Object

object to be cloned

Return:

Object

public divideEmail(email: *): * source

import {divideEmail} from 'runtime-core/src/utils/utils.js'

Params:

NameTypeAttributeDescription
email *

Return:

*

public divideURL(url: URL.URL): divideURL source

import {divideURL} from 'runtime-core/src/utils/utils.js'

Divide an url in type, domain and identity

Params:

NameTypeAttributeDescription
url URL.URL

url address

Return:

divideURL

the result of divideURL

public emptyObject(object: Object): Boolean source

import {emptyObject} from 'runtime-core/src/utils/utils.js'

Check if an Object is empty

Params:

NameTypeAttributeDescription
object Object

Object to be checked

Return:

Boolean

status of Object, empty or not (true|false);

public generateGUID(): * source

import {generateGUID} from 'runtime-core/src/utils/utils.js'

Generate a Global Unique ID

Return:

*

String;

public getConfigurationResources(configuration: object, component: string, resource: string): object source

import {getConfigurationResources} from 'runtime-core/src/utils/utils.js'

get information relative each component configured on runtime configuration;

Params:

NameTypeAttributeDescription
configuration object

object with all configuration

component string

string with the component to get the configuration, like, runtimeURLS, catalogueURLs, msgNodeURL, domainRegistryURL;

resource string

type of resource to get, like, catalogue, runtimeUA, protocolstub, idpProxy

Return:

object

return an object with all configurations;

public getUserEmailFromURL(userURL: URL.URL): string source

import {getUserEmailFromURL} from 'runtime-core/src/utils/utils.js'

Obtains the user email that corresponds to a given URL

Params:

NameTypeAttributeDescription
userURL URL.URL

The user URL

Return:

string

userEmail The user email

public getUserIdentityDomain(url: *): * source

import {getUserIdentityDomain} from 'runtime-core/src/utils/utils.js'

Params:

NameTypeAttributeDescription
url *

Return:

*

public getUserURLFromEmail(userEmail: string): URL.URL source

import {getUserURLFromEmail} from 'runtime-core/src/utils/utils.js'

Obtains the user URL that corresponds to a given email

Params:

NameTypeAttributeDescription
userEmail string

The user email

Return:

URL.URL

userURL The user URL

public isBackendServiceURL(url: string): boolean source

import {isBackendServiceURL} from 'runtime-core/src/utils/utils.js'

Check if URL is from a backend service

Params:

NameTypeAttributeDescription
url string

URL to be processed

Return:

boolean

public isDataObjectURL(url: *): * source

import {isDataObjectURL} from 'runtime-core/src/utils/utils.js'

Params:

NameTypeAttributeDescription
url *

Return:

*

public isHypertyURL(url: *): * source

import {isHypertyURL} from 'runtime-core/src/utils/utils.js'

Params:

NameTypeAttributeDescription
url *

Return:

*

public isLegacy(url: *): boolean source

import {isLegacy} from 'runtime-core/src/utils/utils.js'

Params:

NameTypeAttributeDescription
url *

Return:

boolean

public isURL(url: *): * source

import {isURL} from 'runtime-core/src/utils/utils.js'

Params:

NameTypeAttributeDescription
url *

Return:

*

public isUserURL(url: *): * source

import {isUserURL} from 'runtime-core/src/utils/utils.js'

Params:

NameTypeAttributeDescription
url *

Return:

*

public parseAttributes(path: *): * source

import {parseAttributes} from 'runtime-core/src/utils/utils.js'

Params:

NameTypeAttributeDescription
path *

Return:

*

public removePathFromURL(url: *): * source

import {removePathFromURL} from 'runtime-core/src/utils/utils.js'

Params:

NameTypeAttributeDescription
url *

Return:

*

public schemaValidation(scheme: *, descriptor: *, value: *) source

import {schemaValidation} from 'runtime-core/src/utils/schemaValidation.js'

Params:

NameTypeAttributeDescription
scheme *
descriptor *
value *

public splitObjectURL(dataObjectURL: *): * source

import {splitObjectURL} from 'runtime-core/src/utils/utils.js'

Params:

NameTypeAttributeDescription
dataObjectURL *

Return:

*