@netgrif/components-core
Version:
Netgrif Application engine frontend core Angular library
32 lines (31 loc) • 1.47 kB
TypeScript
import { OnDestroy } from '@angular/core';
import { TaskContentService } from './task-content.service';
import { TaskHandlingService } from '../../task/services/task-handling-service';
import { Observable, Subject } from 'rxjs';
import { TaskEventNotification } from '../model/task-event-notification';
import * as i0 from "@angular/core";
/**
* Holds logic about the available operations on a {@link Task} object based on it's state.
*
* Beware that it gets the Task from (@link TaskContentService) instance and thus the task might not be always initialized.
* If the task is not initialized this class cannot work properly.
*/
export declare class TaskEventService extends TaskHandlingService implements OnDestroy {
protected _taskEventNotifications$: Subject<TaskEventNotification>;
constructor(_taskContentService: TaskContentService);
/**
* Completes the stream
*/
ngOnDestroy(): void;
/**
* Provides information about results of events executed on the managed {@link Task}
*/
get taskEventNotifications$(): Observable<TaskEventNotification>;
/**
* Emits a new {@link TaskEventNotification} into the notifications stream
* @param event the event information that will be pushed into the stream
*/
publishTaskEvent(event: TaskEventNotification): void;
static ɵfac: i0.ɵɵFactoryDeclaration<TaskEventService, never>;
static ɵprov: i0.ɵɵInjectableDeclaration<TaskEventService>;
}