# All files / src ddfcsv-error.ts

100% Statements 10/10
100% Branches 0/0
100% Functions 1/1
100% Lines 10/10

Press n or j to go to the next uncovered block, b, p or k for the previous block.

    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    221x
    1x
    1x
    1x

    1x

    29x
    29x
    29x
    29x
    29x

     export const FILE_READING_ERROR = 'File reading error';
    export const JSON_PARSING_ERROR = 'JSON parsing error';
    export const CSV_PARSING_ERROR = 'CSV parsing error';
    export const DDF_ERROR = 'DDF error';

    /* tslint: disable-next-line */
    export class DdfCsvError extends Error {
      public details: any;
      public file: string | null;
      public stack: string;
      public name: string;
      public message: string;

      constructor(message: string, details, file?: string) {
        super();
        this.name = 'DdfCsvError';
        this.message = `${message} [filepath: ${file}]. ${details}.`;
        this.details = details;
        this.file = file;
      }
    }