File

src/lib/any-http-error/any-http-error.service.ts

Extends

ErrorCaptureService

Index

Properties
Methods

Methods

compare
compare(a: Error, b: Error)
Inherited from ErrorCaptureService
Parameters :
Name Type Optional
a Error No
b Error No
Returns : boolean
openDialog
openDialog(errorList: WritableSignal)
Inherited from ErrorCaptureService
Parameters :
Name Type Optional
errorList WritableSignal<Error[]> No
Returns : void
push
push(error: Error)
Inherited from ErrorCaptureService
Parameters :
Name Type Optional
error Error No
Returns : void

Properties

Protected Readonly component
Type : ComponentType<IErrorDialogComponent>
Default value : AnyHttpErrorComponent
Inherited from ErrorCaptureService
import { ComponentType } from '@angular/cdk/overlay';
import { Injectable } from '@angular/core';
import { ErrorCaptureService } from '../error-capture.service';
import { IErrorDialogComponent } from '../error-dialog/error-dialog.component';
import { AnyHttpErrorDialogData } from './any-http-error-dialog-data';
import { AnyHttpErrorComponent } from './any-http-error.component';

@Injectable({ providedIn: 'root' })
export class AnyHttpErrorService<Error extends AnyHttpErrorDialogData = AnyHttpErrorDialogData>
  extends ErrorCaptureService<Error> {

  protected readonly component: ComponentType<IErrorDialogComponent> = AnyHttpErrorComponent;

  override compare(a: Error, b: Error): boolean {
    return a.url === b.url && a.method === b.method && a.status === b.status && a.message === b.message;
  }

}

results matching ""

    No results matching ""