Index

core/common/virtual-scroll/virtual-scroll-window.directive.ts

_virtualScrollWindowStrategyFactory
_virtualScrollWindowStrategyFactory(windowDir: VirtualScrollWindowDirective)

Provider factory for VirtualScrollWindowStrategy that simply extracts the already created VirtualScrollWindowStrategy from the given directive.

Parameters :
Name Type Optional Description
windowDir VirtualScrollWindowDirective No

The instance of VirtualScrollWindowDirective to extract the VirtualScrollWindowStrategy from.

upgrade/absolute-date.service.ts

absoluteDateServiceFactory
absoluteDateServiceFactory(datePipe: DatePipe)
Parameters :
Name Type Optional
datePipe DatePipe No

polyfills/index.ts

addPolyfills
addPolyfills()

core/alert/alert-on-error.ts

alertOnError
alertOnError(result: Promise)

Checks for errors in responses of requests made with @c8y/client services and displays them as alerts using AlertService.

Example

   const devices = await alertOnError(inventoryService.list({...}));
Parameters :
Name Type Optional Description
result Promise No

The result object from the @c8y/client service method

Returns : Promise<T>

The original response (success or failure) of the @c8y/client service method invokation

core/common/extension-hooks.ts

allEntriesAreEqual
allEntriesAreEqual(previous: Array, next: Array)
Parameters :
Name Type Optional
previous Array No
next Array No
Returns : boolean
fromFactories
fromFactories(factories?: Array, router?: Router, withFirstEmpty)
Parameters :
Name Type Optional Default value
factories Array Yes
router Router Yes
withFirstEmpty No true
Returns : Observable<T[]>
fromTrigger
fromTrigger(router: Router, refresh, factories: Array)
Parameters :
Name Type Optional
router Router No
refresh No
factories Array No
Returns : Observable<T[]>
fromTriggerOnce
fromTriggerOnce(router: Router, refresh, factories: Array)
Parameters :
Name Type Optional
router Router No
refresh No
factories Array No
Returns : Observable<T[]>
getActivatedRoute
getActivatedRoute(router: Router)

Helper function to get the activated route in a service (as ActivatedRoute injection only works in components). Works as long as we only use a tree and no child is active at the same time.

Parameters :
Name Type Optional Description
router Router No

The current router

Returns : ActivatedRoute
getInjectedHooks
getInjectedHooks(token: InjectionToken, injectors, type)
Parameters :
Name Type Optional Default value
token InjectionToken No
injectors No
type No InjectionType.COMPONENT
Returns : T[]
hookGeneric
hookGeneric(items, token: InjectionToken, options?: Partial)

A generic function to be used by specific implementations of the HOOK concept.

Parameters :
Name Type Optional Description
items No

The items that should be provided under the useValue or useClass attribute. Allows an extension factory to be passed as an argument, which can create instances of type T.

token InjectionToken No

The InjectionToken/HOOK to be provided.

options Partial Yes

If this is a multi provider or not (defaults to true) and provider type definition (defaults to ClassProvider) - HookOptions.

Returns : ValueProvider | ClassProvider | ExistingProvider

A Provider (either ValueProvider or ClassProvider) to be provided in a module.

isExtensionFactory
isExtensionFactory(obj: any)
Parameters :
Name Type Optional
obj any No
isPromise
isPromise(obj: any)
Parameters :
Name Type Optional
obj any No
Returns : Promise<T>
removeDuplicatesIds
removeDuplicatesIds(items)
Parameters :
Name Optional
items No
Returns : T[]
resolveInjectedFactories
resolveInjectedFactories(factories: Array)
Parameters :
Name Type Optional
factories Array No
sortByPriority
sortByPriority(items)
Parameters :
Name Optional
items No
Returns : T[]
stateToFactory
stateToFactory(componentsState)
Parameters :
Name Optional
componentsState No
toObservable
toObservable(value)

Converts any value provided to an Observable that emits this value once and then completes. A convenience method to represent all the data as Observables rather than a mixture of Observables and other types.

Parameters :
Name Optional Description
value No

The value the resulting Observable will emit.

Returns : Observable<T>
toObservableOfArrays
toObservableOfArrays(factoryResult, withFirstEmpty: boolean)
Parameters :
Name Type Optional
factoryResult No
withFirstEmpty boolean No
Returns : Observable<T[]>

core/file-picker-form-control/file-picker-form-control.component.ts

appendErrors
appendErrors(errors: ValidationErrors, newErrors)
Parameters :
Name Type Optional
errors ValidationErrors No
newErrors No
Returns : ValidationErrors

core/forms/validate-array-elements.ts

asyncValidateArrayElements
asyncValidateArrayElements(validator: AsyncValidatorFn)

Async version of validateArrayElements.

Note that Angular by design doesn't execute async validators if synchronous validators returns any error.

Parameters :
Name Type Optional
validator AsyncValidatorFn No
Returns : AsyncValidatorFn
generateArrayRelatedErrors
generateArrayRelatedErrors(errors: Array)
Parameters :
Name Type Optional
errors Array No
validateArrayElements
validateArrayElements(validator: ValidatorFn)

This method can alter how validators work. It can be used in cases where there is need to validate FormControl that as value, takes array of elements. This allows to reuse validators, that works for such elements. For example if Validators.minLength(3) is used on control that takes string as value, validator will return error if string is less than 3 characters. If same is done on array of strings, validator will return error if array has less than 3 elements.

validateArrayElements(Validators.minLength(3)) method makes it possible to check every member of array if it has minimum 3 characters. If there are elements that raise error, it will be possible to extract these errors using item index.

As a example, this can be used for custom form elements, which manipulates array of elements, and there is need to display corresponding error messages for every array member that is displayed, while still using Angular's Validation approach.

Errors that are generated by this helper are prefixed with 'INNER_ARRAY_ERROR_'. Reason for this is to prevent overwriting normal validation errors that could have same key

Parameters :
Name Type Optional
validator ValidatorFn No
Returns : ValidatorFn

upgrade/auth-bridge.service.ts

authBridgeServiceFactory
authBridgeServiceFactory(injector: any, basicAuth: BasicAuth, fetchClient: FetchClient, appState: AppStateService, tenantUiService: TenantUiService)
Parameters :
Name Type Optional
injector any No
basicAuth BasicAuth No
fetchClient FetchClient No
appState AppStateService No
tenantUiService TenantUiService No

upgrade/bridge.service.ts

bridgeServiceFactory
bridgeServiceFactory(injector: any, appState: AppStateService, router: Router, ngZone: NgZone, routerService: RouterService, actionService: ActionService, plugins: PluginsResolveService)
Parameters :
Name Type Optional
injector any No
appState AppStateService No
router Router No
ngZone NgZone No
routerService RouterService No
actionService ActionService No
plugins PluginsResolveService No

upgrade/ng1/alert.decorator.ts

c8yAlertDecorator
c8yAlertDecorator($delegate, $rootScope, $injector)
Parameters :
Name Optional
$delegate No
$rootScope No
$injector No

upgrade/ng1/navigator.provider.ts

c8yNavigatorProvider
c8yNavigatorProvider()

upgrade/ng1/http.interceptor.ts

c8yNg1HttpInterceptor
c8yNg1HttpInterceptor($q, c8yLoadingIndicator, c8yApiService)
Parameters :
Name Optional
$q No
c8yLoadingIndicator No
c8yApiService No

upgrade/ng1/title.decorator.ts

c8yTitleDecorator
c8yTitleDecorator($q, $delegate, $injector, $rootScope, $location, $templateCache, $compile, c8yHeaderService)
Parameters :
Name Optional
$q No
$delegate No
$injector No
$rootScope No
$location No
$templateCache No
$compile No
c8yHeaderService No

upgrade/ng1/root.component.ts

c8yUiRootController
c8yUiRootController($rootScope, $timeout, c8yBase, c8yNavigator, c8yApplication, c8yHeaderService)
Parameters :
Name Optional
$rootScope No
$timeout No
c8yBase No
c8yNavigator No
c8yApplication No
c8yHeaderService No

core/dynamic-forms/validation/validation-config.factory.ts

c8yValidationConfigFactory
c8yValidationConfigFactory(translate: TranslateService)
Parameters :
Name Type Optional
translate TranslateService No

upgrade/ng1/views.provider.ts

c8yViewsProvider
c8yViewsProvider($routeProvider, c8yTabsProvider, c8yPathUtils)
Parameters :
Name Optional
$routeProvider No
c8yTabsProvider No
c8yPathUtils No

widgets/cockpit/index.ts

cockpitWidgets
cockpitWidgets(excludeList?: Array)

Widgets module to be imported in your app module. The exclude list allows to exclude certain widgets. Calls WidgetsModule.config under the hood with the cockpitDefaultWidgets.


NOTE: The excluded widgets will still be part of your bundle. But as they are lazy loaded should not increase loading duration.


Parameters :
Name Type Optional Description
excludeList Array Yes

allows to exclude specific widgets by their id.

upgrade/dashboard/dashboard-upgrade.module.ts

dashboardBridgeFactory
dashboardBridgeFactory(injector, ngZone, router, contextDashboardService)
Parameters :
Name Optional
injector No
ngZone No
router No
contextDashboardService No

widgets/device-management/index.ts

deviceManagementWidgets
deviceManagementWidgets(excludeList?: Array)

Widgets module to be imported in your app module. The exclude list allows to exclude certain widgets. Calls WidgetsModule.config under the hood with the deviceManagementDefaultWidgets.


NOTE: The excluded widgets will still be part of your bundle. But as they are lazy loaded should not increase loading duration.


Parameters :
Name Type Optional Description
excludeList Array Yes

allows to exclude specific widgets by their id.

connectivity/sim/sim.module.ts

encodeFiles
encodeFiles(model: ProviderProperties, fields)
Parameters :
Name Type Optional
model ProviderProperties No
fields No

widgets/implementations/info-gauge/info-gauge-widget-config/info-gauge-widget-config.component.ts

ensureAtLeastOneDatapointSelectedAndActive
ensureAtLeastOneDatapointSelectedAndActive(datapointListAttributes)
Parameters :
Name Optional
datapointListAttributes No
Returns : ValidatorFn

core/data-grid/grid-data-source.ts

escapeRegExpPattern
escapeRegExpPattern(pattern: string)
Parameters :
Name Type Optional Default value
pattern string No ''

widgets/implementations/kpi/kpi-widget-config/kpi-widget-config.component.ts

exactlyASingleDatapointActive
exactlyASingleDatapointActive()
Returns : ValidatorFn

core/dynamic-forms/dynamic-forms-ui-theme.module.ts

fieldTypeFactory
fieldTypeFactory()

core/i18n/i18n.module.ts

getAngularLocalesLanguageString
getAngularLocalesLanguageString(language: string)
Parameters :
Name Type Optional Default value
language string No 'en'
languagesFactory
languagesFactory(options: OptionsService)
Parameters :
Name Type Optional
options OptionsService No
localeId
localeId(appStateService: AppStateService)
Parameters :
Name Type Optional
appStateService AppStateService No
localePathFactory
localePathFactory(options: OptionsService)
Parameters :
Name Type Optional
options OptionsService No
translateLoaderFactory
translateLoaderFactory(httpClient: HttpClient, optionsService: OptionsService, cachedLocaleDictionaryService: CachedLocaleDictionaryService, localePath: string, languages: any)
Parameters :
Name Type Optional
httpClient HttpClient No
optionsService OptionsService No
cachedLocaleDictionaryService CachedLocaleDictionaryService No
localePath string No
languages any No

core/dynamic-forms/presets.ts

getBasicInputArrayFormFieldConfig
getBasicInputArrayFormFieldConfig(config: BasicInputArrayFormConfigInterface)

Generates simple array formFieldConfig

Parameters :
Name Type Optional
config BasicInputArrayFormConfigInterface No
Returns : FormlyFieldConfig[]

FormlyFieldConfig[]

map/map.model.ts

getC8yMarker
getC8yMarker(marker, asset: PositionManagedObject)
Parameters :
Name Type Optional
marker No
asset PositionManagedObject No
getStatus
getStatus(device: PositionManagedObject)
Parameters :
Name Type Optional
device PositionManagedObject No

core/plugins/__test__/plugins-test-helper.ts

getRemoteTestingModule
getRemoteTestingModule(providers, providersSubModule?)
Parameters :
Name Optional
providers No
providersSubModule Yes
Returns : Type<any>

core/i18n/gettext.ts

gettext
gettext(str: T)
Parameters :
Name Type Optional
str T No
Returns : T

upgrade/ng1/gettextCatalog.decorator.ts

gettextCatalogDecorator
gettextCatalogDecorator($delegate, $interpolate, c8yTranslate)
Parameters :
Name Optional
$delegate No
$interpolate No
c8yTranslate No

upgrade/ng1/groupsHierarchyNavigator.decorator.ts

groupTypesHierarchyNavigatorDecorator
groupTypesHierarchyNavigatorDecorator($delegate, $q)
Parameters :
Name Optional
$delegate No
$q No

core/action/action.service.ts

hookAction
hookAction(actions: GenericHookType, options?: Partial)

A hook to add an action using the multi-provider extension concept.

You can either provide a single Action as parameter:

 hookAction(...)

Or an array to directly register multiple:

 hookAction([...])

Or you provide an Service that implements ExtensionFactory<Action>

 export class MyActionFactory implements ExtensionFactory<Action> {...}
 ...
 hookAction(MyActionFactory)

A typed alternative to HOOK_ACTION.

Parameters :
Name Type Optional Description
actions GenericHookType No

The Action's or ExtensionFactory to be provided.

options Partial Yes

core/action-bar/action-bar.service.ts

hookActionBar
hookActionBar(items: GenericHookType, options?: Partial)

A hook to add ActionBarItems using the multi provider extension concept.

You can either provide a single ActionBarItem as parameter:

 hookActionBar(...)

Or an array to directly register multiple:

 hookActionBar([...])

Or you provide an Service that implements ExtensionFactory<ActionBarItem>

 export class MyActionBarFactory implements ExtensionFactory<ActionBarItem> {...}
 ...
 hookActionBar(MyActionBarFactory)

A typed alternative to HOOK_ACTION_BAR.

Parameters :
Name Type Optional Description
items GenericHookType No

The ActionBarItem's or ExtensionFactory to be provided.

options Partial Yes

core/breadcrumb/breadcrumb.service.ts

hookBreadcrumb
hookBreadcrumb(breadcrumb: GenericHookType, options?: Partial)

You can either provide a single Breadcrumb as parameter:

 hookBreadcrumb(...)

Or an array to directly register multiple:

 hookBreadcrumb([...])

Or you provide an Service that implements ExtensionFactory<Breadcrumb>

 export class MyBreadcrumbFactory implements ExtensionFactory<Breadcrumb> {...}
 ...
 hookBreadcrumb(MyBreadcrumbFactory)

A typed alternative to HOOK_BREADCRUMB.

Parameters :
Name Type Optional Description
breadcrumb GenericHookType No

The Breadcrumb's or ExtensionFactory to be provided.

options Partial Yes

core/dynamic-component/dynamic-component.model.ts

hookComponent
hookComponent(components: GenericHookType, options?: Partial)

A hook to add dynamic components to the UI (e.g. widgets).

You can either provide a single DynamicComponentDefinition as parameter:

 hookComponent(...)

Or an array to directly register multiple:

 hookComponent([...])

Or you provide an Service that implements ExtensionFactory<DynamicComponentDefinition>

 export class MyDynamicComponentDefinitionFactory implements ExtensionFactory<DynamicComponentDefinition> {...}
 ...
 hookComponent(MyDynamicComponentDefinitionFactory)

A typed alternative to HOOK_COMPONENTS.

Parameters :
Name Type Optional Description
components GenericHookType No

The DynamicComponentDefinition's or ExtensionFactory to be provided.

options Partial Yes
isEagerDynamicComponents
isEagerDynamicComponents(componentDefinition: DynamicComponents)
Parameters :
Name Type Optional
componentDefinition DynamicComponents No
isLazyDynamicComponents
isLazyDynamicComponents(componentDefinition: DynamicComponents)
Parameters :
Name Type Optional
componentDefinition DynamicComponents No

device-grid/device-grid-extension.service.ts

hookDeviceGridAction
hookDeviceGridAction(action: GenericHookType, options?: Partial)

You can either provide a single DeviceGridActionExtension as parameter:

 hookDeviceGridAction(...)

Or an array to directly register multiple:

 hookDeviceGridAction([...])

Or you provide an Service that implements ExtensionFactory<DeviceGridActionExtension>

 export class MyDeviceGridActionFactory implements ExtensionFactory<DeviceGridActionExtension> {...}
 ...
 hookDeviceGridAction(MyDeviceGridActionFactory)

A typed alternative to HOOK_DEVICE_GRID_ACTION_DELETE.

Parameters :
Name Type Optional Description
action GenericHookType No

The DeviceGridDeleteExtension's or ExtensionFactory to be provided.

options Partial Yes

device-list/device-list-extension.service.ts

hookDeviceListColumns
hookDeviceListColumns(columns: HookValueType, options?: Partial)

A hook to override the default device grid columns configuration in c8y-device-list component.

Parameters :
Name Type Optional
columns HookValueType No
options Partial Yes

register-device/dropdown/register-device-extension.service.ts

hookDeviceRegistration
hookDeviceRegistration(registration: GenericHookType, options?: Partial)

You can either provide a single RegisterDeviceExtension as parameter:

 hookDeviceRegistration(...)

Or an array to directly register multiple:

 hookDeviceRegistration([...])

Or you provide an Service that implements ExtensionFactory<RegisterDeviceExtension>

 export class MyDeviceRegistrationFactory implements ExtensionFactory<RegisterDeviceExtension> {...}
 ...
 hookDeviceRegistration(MyDeviceRegistrationFactory)

A typed alternative to HOOK_DEVICE_REGISTRATION.

Parameters :
Name Type Optional Description
registration GenericHookType No

The RegisterDeviceExtension's or ExtensionFactory to be provided.

options Partial Yes

core/docs/docs.models.ts

hookDocs
hookDocs(doc: GenericHookType)

You can either provide a single DocLink as parameter:

 hookOptions(...)

Or an array to directly register multiple:

 hookOptions([...])

Or you provide an Service that implements ExtensionFactory<DocLink> ```typescript

Parameters :
Name Type Optional Description
doc GenericHookType No

The DocLink's or ExtensionFactory to be provided.

core/drawer/drawer.service.ts

hookDrawer
hookDrawer(drawer: GenericHookType, options?: Partial)

You can either provide a single DrawerItem as parameter:

 hookDrawer(...)

Or an array to directly register multiple:

 hookDrawer([...])

Or you provide a Service that implements ExtensionFactory<DrawerItem>

 export class MyDrawerFactory implements ExtensionFactory<DrawerItem> {...}
 ...
 hookDrawer(MyDrawerFactory)

A typed alternative to HOOK_DRAWER.

Parameters :
Name Type Optional Description
drawer GenericHookType No

The DrawerItem's or ExtensionFactory to be provided.

options Partial Yes

core/provider-configuration/provider-configuration-hook.ts

hookDynamicProviderConfig
hookDynamicProviderConfig(config: GenericHookType, options?: Partial)

You can either provide a single DynamicProviderConfig as parameter:

 hookDynamicProviderConfig(...)

Or an array to directly register multiple:

 hookDynamicProviderConfig([...])

Or you provide an Service that implements ExtensionFactory<DynamicProviderConfig>

 export class MyDynamicProviderConfigFactory implements ExtensionFactory<DynamicProviderConfig> {...}
 ...
 hookDynamicProviderConfig(MyDynamicProviderConfigFactory)

A typed alternative to HOOK_DYNAMIC_PROVIDER_CONFIG.

Parameters :
Name Type Optional Description
config GenericHookType No

The DynamicProviderConfig's or ExtensionFactory to be provided.

options Partial Yes

core/data-grid/filter-chip/filter-mapper.factory.ts

hookFilterMapper
hookFilterMapper(mapper: HookValueType, options?: Partial)

You can either provide a single FilterMapper as parameter:

 hookFilterMapper(...)

Or an array to directly register multiple:

 hookFilterMapper([...])

Or you provide an Service that implements FilterMapper

 export class MyFilterMapper implements FilterMapper {...}
 ...
 hookFilterMapper(MyFilterMapper)

A typed alternative to using HOOK_FILTER_MAPPER.

Parameters :
Name Type Optional Description
mapper HookValueType No

A filter mapper, e.g. BooleanFilterMapper, or ExtensionFactory to be provided.

options Partial Yes

If this is a multi provider or not (defaults to true) and provider type definition (defaults to ClassProvider) - HookOptions.

operations/bulk-operations-service/bulk-operations.service.ts

hookListBulkType
hookListBulkType(type: GenericHookType, options?: Partial)

You can either provide a single OperationType as parameter:

 hookListBulkType(...)

Or an array to directly register multiple:

 hookListBulkType([...])

Or you provide an Service that implements ExtensionFactory<OperationType>

 export class MyListBulkTypeFactory implements ExtensionFactory<OperationType> {...}
 ...
 hookListBulkType(MyListBulkTypeFactory)

A typed alternative to HOOK_LIST_BULK_TYPE.

Parameters :
Name Type Optional Description
type GenericHookType No

The OperationType's or ExtensionFactory to be provided.

options Partial Yes

core/navigator/navigator.service.ts

hookNavigator
hookNavigator(nodes: GenericHookType, options?: Partial)

You can either provide a single NavigatorNode or NavigatorNodeData as parameter:

 hookNavigator(...)

Or an array to directly register multiple:

 hookNavigator([...])

Or you provide an Service that implements ExtensionFactory<NavigatorNode | NavigatorNodeData>

 export class MyNavigatorFactory implements ExtensionFactory<NavigatorNode | NavigatorNodeData> {...}
 ...
 hookNavigator(MyNavigatorFactory)

A typed alternative to HOOK_NAVIGATOR_NODES.

Parameters :
Name Type Optional Description
nodes GenericHookType No

The NavigatorNode's, NavigatorNodeData's or ExtensionFactory to be provided.

options Partial Yes

core/common/options.service.ts

hookOptions
hookOptions(options: GenericHookType, hookOptions?: Partial)

You can either provide a single ApplicationOptions as parameter:

 hookOptions(...)

Or an array to directly register multiple:

 hookOptions([...])

Or you provide an Service that implements ExtensionFactory<ApplicationOptions>

 export class MyApplicationOptionsFactory implements ExtensionFactory<ApplicationOptions> {...}
 ...
 hookOptions(MyApplicationOptionsFactory)

A typed alternative to HOOK_OPTIONS.

Parameters :
Name Type Optional Description
options GenericHookType No

The ApplicationOptions's or ExtensionFactory to be provided.

hookOptions Partial Yes

core/i18n/patterns-message.hook.ts

hookPatternMessages
hookPatternMessages(patterns: GenericHookType, options?: Partial)

You can either provide a single PatternMessages as parameter:

 hookPatternMessages(...)

Or an array to directly register multiple:

 hookPatternMessages([...])

Or you provide an Service that implements ExtensionFactory<PatternMessages>

 export class MyPatternMessagesFactory implements ExtensionFactory<PatternMessages> {...}
 ...
 hookPatternMessages(MyPatternMessagesFactory)

A typed alternative to HOOK_PATTERN_MESSAGES.

Parameters :
Name Type Optional Description
patterns GenericHookType No

The PatternMessages's or ExtensionFactory to be provided.

options Partial Yes

core/router/router.service.ts

hookRoute
hookRoute(route: GenericHookType, options?: Partial)

You can either provide a single Route as parameter:

 hookRoute(...)

Or an array to directly register multiple:

 hookRoute([...])

Or you provide an Service that implements ExtensionFactory<Route>

 export class MyRouteFactory implements ExtensionFactory<Route> {...}
 ...
 hookRoute(MyRouteFactory)

A typed alternative to HOOK_ROUTE.

Parameters :
Name Type Optional Description
route GenericHookType No

The Route's or ExtensionFactory to be provided.

options Partial Yes

core/search/search.service.ts

hookSearch
Please don't use the search factory. It will be refactored soon.
hookSearch(search: GenericHookType, options?: Partial)

You can either provide a single Search as parameter:

 hookSearch(...)

Or an array to directly register multiple:

 hookSearch([...])

Or you provide an Service that implements ExtensionFactory<Search>

 export class MySearchFactory implements ExtensionFactory<Search> {...}
 ...
 hookSearch(MySearchFactory)

A typed alternative to HOOK_SEARCH.

Parameters :
Name Type Optional Description
search GenericHookType No

The Search's or ExtensionFactory to be provided.

options Partial Yes

services/status-options/status-options.model.ts

hookServiceStatus
hookServiceStatus(status: GenericHookType, options?: Partial)

Extension hook allowing to register custom service statuses and configure their visual presentation.

You can either provide a single StatusOption as parameter:

 hookServiceStatus(...)

Or an array to directly register multiple:

 hookServiceStatus([...])

Or you provide an Service that implements ExtensionFactory<StatusOption>

 export class MyServiceStatusFactory implements ExtensionFactory<StatusOption> {...}
 ...
 hookServiceStatus(MyServiceStatusFactory)

A typed alternative to HOOK_SERVICE_STATUS.

Parameters :
Name Type Optional Description
status GenericHookType No

The StatusOption's or ExtensionFactory to be provided.

options Partial Yes

core/stepper/stepper.service.ts

hookStepper
hookStepper(step: GenericHookType, options?: Partial)

You can either provide a single Step as parameter:

 hookStepper(...)

Or an array to directly register multiple:

 hookStepper([...])

Or you provide an Service that implements ExtensionFactory<Step>

 export class MyStepFactory implements ExtensionFactory<Step> {...}
 ...
 hookStepper(MyStepFactory)

A typed alternative to HOOK_STEPPER.

Parameters :
Name Type Optional Description
step GenericHookType No

The Step's or ExtensionFactory to be provided.

options Partial Yes

core/tabs/tabs.service.ts

hookTab
hookTab(tabs: GenericHookType, options?: Partial)

You can either provide a single Tab as parameter:

 hookTab(...)

Or an array to directly register multiple:

 hookTab([...])

Or you provide an Service that implements ExtensionFactory<Tab>

 export class MyTabFactory implements ExtensionFactory<Tab> {...}
 ...
 hookTab(MyTabFactory)

A typed alternative to HOOK_TABS.

Parameters :
Name Type Optional Description
tabs GenericHookType No

The Tab's or ExtensionFactory to be provided.

options Partial Yes

core/version/version.model.ts

hookVersion
hookVersion(versions: GenericHookType, options?: Partial)

You can either provide a single Version as parameter:

 hookVersion(...)

Or an array to directly register multiple:

 hookVersion([...])

Or you provide an Service that implements ExtensionFactory<Version>

 export class MyVersionFactory implements ExtensionFactory<Version> {...}
 ...
 hookVersion(MyVersionFactory)

A typed alternative to HOOK_VERSION.

Parameters :
Name Type Optional Description
versions GenericHookType No

The Version's or ExtensionFactory to be provided.

options Partial Yes

core/wizard/wizard.model.ts

hookWizard
hookWizard(wizard: GenericHookType, options?: Partial)

A hook to add wizard entries.

You can either provide a single WizardEntry as parameter:

 hookWizard(...)

Or an array to directly register multiple:

 hookWizard([...])

Or you provide an Service that implements ExtensionFactory<WizardEntry>

 export class MyWizardFactory implements ExtensionFactory<WizardEntry> {...}
 ...
 hookWizard(MyWizardFactory)

A typed alternative to HOOK_WIZARD.

Parameters :
Name Type Optional Description
wizard GenericHookType No

The WizardEntry's or ExtensionFactory to be provided.

options Partial Yes

core/common/common.module.ts

initializeServices
initializeServices(translateService: TranslateService, state: AppStateService, userPreferences: UserPreferencesService)
Parameters :
Name Type Optional
translateService TranslateService No
state AppStateService No
userPreferences UserPreferencesService No

protocol-lpwan/multiple-lns-connectors/multiple-lns-connector.model.ts

isActilityConnection
isActilityConnection(connection)
Parameters :
Name Optional
connection No
Returns : ActilityConnection
isLoriotConnection
isLoriotConnection(connection)
Parameters :
Name Optional
connection No
Returns : LoriotConnection
isSigfoxConnection
isSigfoxConnection(connection)
Parameters :
Name Optional
connection No
Returns : SigfoxConnection

auth-configuration/basic-settings/basic-settings.model.ts

isBasic
isBasic(tenantLoginOption: TenantLoginOption)
Parameters :
Name Type Optional
tenantLoginOption TenantLoginOption No
isOauthInternal
isOauthInternal(tenantLoginOption: TenantLoginOption)
Parameters :
Name Type Optional
tenantLoginOption TenantLoginOption No

sub-assets/fullscreen.util.ts

isFullScreenEnabled
isFullScreenEnabled(element)
Parameters :
Name Optional
element No
toggleFullscreen
toggleFullscreen(element)
Parameters :
Name Optional
element No

replace-device-wizard/replace-device-wizard.model.ts

isValidReplaceDeviceStepState
isValidReplaceDeviceStepState(state)
Parameters :
Name Optional
state No

widgets/implementations/three-d-rotation/lazy-box-model/lazy-load-box-model.ts

loadBoxModel
loadBoxModel()

core/i18n/__mocks__/load-locale.ts

loadLocale
loadLocale(_moduleLang)
Parameters :
Name Optional
_moduleLang No

lazy/three-orbit-controls/index.ts

loadOrbitControls
loadOrbitControls()

Dynamically imports the OrbitControls of three js.

Returns : Promise<>

A Promise of OrbitControls (three js).

widgets/implementations/three-d-rotation/lazy-phone-model/lazy-load-phone-model.ts

loadPhoneModel
loadPhoneModel()

lazy/three/index.ts

loadThree
loadThree()

Dynamically imports three js.

Returns : Promise<>

A Promise of three js.

core/common/memoize.decorator.ts

memoize
memoize(resolver?)

Decorator to memoize function results.

Parameters :
Name Optional Description
resolver Yes

Cache key resolver function, used by memoize from lodash.

core/dynamic-forms/i18n/translate.extension.ts

registerTranslateExtension
registerTranslateExtension(translate: TranslateService, parser: TranslateParser)
Parameters :
Name Type Optional
translate TranslateService No
parser TranslateParser No

core/common/retry-with-delay.operator.ts

retryWithDelay
retryWithDelay(delayTime: number, count: number)
Parameters :
Name Type Optional Default value
delayTime number No
count number No 1
Returns : MonoTypeOperatorFunction<T>

upgrade/upgraded-services/roles.service.ts

RolesServiceFactory
RolesServiceFactory(injector)
Parameters :
Name Optional
injector No

device-protocols/device-type-detail.component.ts

rootScopeFactory
rootScopeFactory($injector: Injector)
Parameters :
Name Type Optional
$injector Injector No

device-shell/command-templates/command-templates.component.ts

rootScopeFactory
rootScopeFactory($injector: Injector)
Parameters :
Name Type Optional
$injector Injector No

core/forms/simple-json-path-validator.directive.ts

simpleJsonPathValidator
simpleJsonPathValidator(control: AbstractControl)
Parameters :
Name Type Optional
control AbstractControl No
Returns : ValidationErrors | null

upgrade/smart-rules.service.ts

SmartRulesServiceFactory
SmartRulesServiceFactory(injector: any)
Parameters :
Name Type Optional
injector any No

core/common/number.pipe.ts

strToNumber
strToNumber(value)

Transforms a string into a number (if needed).

Parameters :
Name Optional
value No
Returns : number

core/common/throttle.decorator.ts

throttle
throttle(wait?, options?)

Decorator to throttle functions call.

Parameters :
Name Optional Description
wait Yes

throttle time.

options Yes

set triggers, eg on trailing edge or falling edge, see lodash documentation for details

api/data.module.ts

toProvider
toProvider(provide: Type)
Parameters :
Name Type Optional
provide Type No
Returns : Provider

core/i18n/translate.loader.ts

trimTranslationKey
trimTranslationKey(key)

Returns a trimmed translation key. If the key contains HTML, it also removes all whitespaces. The reason behind it is that by default Angular compiler removes whitespaces from adjacent inline elements, which prevents ngx-translate from finding a matching entry in the dictionary.

Parameters :
Name Optional
key No

core/forms/unique-in-collection-by-path-validation.directive.ts

uniqueInCollectionByPathValidator
uniqueInCollectionByPathValidator(collection: Iterable, path: string, comparator?)
Parameters :
Name Type Optional
collection Iterable No
path string No
comparator Yes
Returns : ValidatorFn

upgrade/upgraded-services/user-inventory-roles.service.ts

UserInventoryRolesFactory
UserInventoryRolesFactory(injector)
Parameters :
Name Optional
injector No

results matching ""

    No results matching ""