Please note, this is a STATIC archive of website developer.mozilla.org from 03 Nov 2016, cach3.com does not collect or store any user information, there is no "phishing" involved.

SyntaxError.prototype

This article needs an editorial review. How you can help.

La propietat SyntaxError.prototype representa el prototip pel constructor SyntaxError.

Descripció

Totes les instàncies SyntaxError hereten de SyntaxError.prototype. Es pot utilitzar el prototipus per afegir propietats o mètodes a totes les instàncies.

Propietats

SyntaxError.prototype.constructor
Especifica la funció que ha creat el prototip d'una instància.
SyntaxError.prototype.message
Missatge d'error. Tot i que l'ECMA-262 especifica que SyntaxError hauria de proveir la seva pròpia propietat message, en SpiderMonkey, hereta Error.prototype.message.
SyntaxError.prototype.name
Nom de l'herror. Heretat de Error.
SyntaxError.prototype.fileName
Ruta a l'arxiu que llança aquest error. Heretat de Error.
SyntaxError.prototype.lineNumber
Número de línia en el fitxa que llança aquest error. Heretat de Error.
SyntaxError.prototype.columnNumber
Número de columna en línia que llança aquest error. Heretat de Error.
SyntaxError.prototype.stack
Traça de l'error. Heretat de Error.

Mètodes

Tot i que l'objecte prototip SyntaxError no conté cap mètode per si mateix, instàncies deSyntaxError heretes alguns mètodes a través de la cadena prototip.

Especificacions

Especificació Estat Comentaris
ECMAScript 3rd Edition (ECMA-262) Standard Definició inicial
ECMAScript 5.1 (ECMA-262)
The definition of 'NativeError.prototype' in that specification.
Standard Definit com a NativeError.prototype.
ECMAScript 2015 (6th Edition, ECMA-262)
The definition of 'NativeError.prototype' in that specification.
Standard Definit com a NativeError.prototype.

Compatibilitat amb navegadors

Característica Chrome Firefox (Gecko) Internet Explorer Opera Safari
Suport bàsic (Yes) (Yes) (Yes) (Yes) (Yes)
Característica Android Chrome per Android Firefox Mobile (Gecko) IE Mobile Opera Mobile Safari Mobile
Suport bàsic (Yes) (Yes) (Yes) (Yes) (Yes) (Yes)

Vegeu també

Document Tags and Contributors

 Contributors to this page: llue
 Last updated by: llue,