Options
All
  • Public
  • Public/Protected
  • All
Menu

Class AuditService

Hierarchy

Index

Constructors

Methods

Constructors

constructor

Methods

create

  • Parameters

    Returns Promise<IResult<IAuditRecord>>

    Response wrapped in IResult

    Example

    
     const mandantoryObject: IAuditRecord = {
       type: AuditRecordType.ALARM,
       time: '2018-05-02T10:08:00Z',
       severity: Severity.MAJOR,
       source: {id: 1}
     };
    
     (async () => {
       const {data, res} = await auditService.create(mandantoryObject);
     })();
    

detail

  • Parameters

    Returns Promise<IResult<IAuditRecord>>

    Response wrapped in IResult

    Example

    
       const auditId: number = 1;
    
       (async () => {
         const {data, res} = await auditService.detail(auditId);
      })();
    

list

list$

  • Parameters

    Returns Observable<IAuditRecord[]>

    Data wrapped as Observable.

    Example

    
      const list$ = auditService.list$();
      list$.subscribe((data) => console.log(data));
    

    Deprecated This function will be removed soon in favor of decoupling this library from rxjs. Use Realtime for realtime connection and rxjs defer() or from() to composite an observable on your own.

Generated using TypeDoc