
import { localize } from '../../nls.js';
import { ParseErrorCode } from './json.js';

function getParseErrorMessage(errorCode) {
    switch (errorCode) {
    case ParseErrorCode.InvalidSymbol:
        return localize(114, "Invalid symbol");
    case ParseErrorCode.InvalidNumberFormat:
        return localize(115, "Invalid number format");
    case ParseErrorCode.PropertyNameExpected:
        return localize(116, "Property name expected");
    case ParseErrorCode.ValueExpected:
        return localize(117, "Value expected");
    case ParseErrorCode.ColonExpected:
        return localize(118, "Colon expected");
    case ParseErrorCode.CommaExpected:
        return localize(119, "Comma expected");
    case ParseErrorCode.CloseBraceExpected:
        return localize(120, "Closing brace expected");
    case ParseErrorCode.CloseBracketExpected:
        return localize(121, "Closing bracket expected");
    case ParseErrorCode.EndOfFileExpected:
        return localize(122, "End of file expected");
    default:
        return "";
    }
}

export { getParseErrorMessage };
