UNPKG

@netgrif/components-core

Version:

Netgrif Application engine frontend core Angular library

63 lines (62 loc) 3.87 kB
import { ProcessService } from '../../../process/process.service'; import { AllowedNetsService } from '../allowed-nets.service'; import { Observable } from 'rxjs'; import { PetriNetResourceService } from '../../../resources/engine-endpoint/petri-net-resource.service'; import { ConfigurationService } from '../../../configuration/configuration.service'; import { LoggerService } from '../../../logger/services/logger.service'; import { InjectedTabbedTaskViewData } from '../../../view/task-view/models/injected-tabbed-task-view-data'; import { Case } from '../../../resources/interface/case'; import { DataGroup } from '../../../resources/public-api'; import { BaseAllowedNetsService } from '../base-allowed-nets.service'; import * as i0 from "@angular/core"; /** * Convenience method that can be used as an allowed nets factory for tabbed task views. * If no allowed nets are provided in the injected data then an {@link AllowedNetsService} with no allowed nets is created. * It has a dependency on this class and {@link NAE_TAB_DATA} injection token. */ export declare function tabbedAllowedNetsServiceFactory(factory: AllowedNetsServiceFactory, tabData: InjectedTabbedTaskViewData): AllowedNetsService; /** * Convenience method that can be used as an allowed nets factory for views that are loaded from filter process instances. * It has a dependency on this class and {@link NAE_NAVIGATION_ITEM_TASK_DATA} injection token. */ export declare function navigationItemTaskAllowedNetsServiceFactory(factory: AllowedNetsServiceFactory, baseAllowedNets: BaseAllowedNetsService, navigationItemTaskData?: Array<DataGroup>): AllowedNetsService; /** * Simplifies the creation of {@link AllowedNetsService} instances */ export declare class AllowedNetsServiceFactory { protected _processService: ProcessService; protected _petriNetResource: PetriNetResourceService; protected _configService: ConfigurationService; protected _log: LoggerService; constructor(_processService: ProcessService, _petriNetResource: PetriNetResourceService, _configService: ConfigurationService, _log: LoggerService); /** * Creates an instance of {@link AllowedNetsService} without having to provide all the dependencies yourself. * @returns an instance of {@link AllowedNetsService} with all nets set as the `allowedNets` */ createWithAllNets(): AllowedNetsService; /** * Creates an instance of {@link AllowedNetsService} without having to provide all the dependencies yourself. * @param allowedNetsIdentifiers identifiers of the allowed nets */ createFromArray(allowedNetsIdentifiers: Array<string>): AllowedNetsService; /** * Creates an instance of {@link AllowedNetsService} without having to provide all the dependencies yourself. * @param webViewPath path to the view as specified in its configuration. No leading backslash. * Allowed nets are loaded from the configuration of the view. */ createFromConfig(webViewPath: string): AllowedNetsService; /** * Creates an instance of {@link AllowedNetsService} without having to provide all the dependencies yourself. * @param netIdentifiers$ observable containing the identifiers of the allowed nets. * When a new value is emitted the allowed nets will be updated. */ createFromObservable(netIdentifiers$: Observable<Array<string>>): AllowedNetsService; /** * Creates an instance of {@link AllowedNetsService} without having to provide all the dependencies yourself. * @param filterCase a filter process instance * Allowed nets are set from filter process immediate data */ createFromFilterCase(filterCase: Case): AllowedNetsService; static ɵfac: i0.ɵɵFactoryDeclaration<AllowedNetsServiceFactory, never>; static ɵprov: i0.ɵɵInjectableDeclaration<AllowedNetsServiceFactory>; }