diff options
Diffstat (limited to 'files/ca/conflicting/web/javascript/reference/global_objects/dataview')
-rw-r--r-- | files/ca/conflicting/web/javascript/reference/global_objects/dataview/index.html | 147 |
1 files changed, 147 insertions, 0 deletions
diff --git a/files/ca/conflicting/web/javascript/reference/global_objects/dataview/index.html b/files/ca/conflicting/web/javascript/reference/global_objects/dataview/index.html new file mode 100644 index 0000000000..ebd6cbe729 --- /dev/null +++ b/files/ca/conflicting/web/javascript/reference/global_objects/dataview/index.html @@ -0,0 +1,147 @@ +--- +title: DataView.prototype +slug: Web/JavaScript/Reference/Global_Objects/DataView/prototype +translation_of: Web/JavaScript/Reference/Global_Objects/DataView +translation_of_original: Web/JavaScript/Reference/Global_Objects/DataView/prototype +--- +<div>{{JSRef}}</div> + +<p>La propietat <code><strong>DataView</strong></code><strong><code>.prototype</code></strong> representa el prototip de l'objecte {{jsxref("DataView")}}.</p> + +<div>{{js_property_attributes(0,0,0)}}</div> + +<h2 id="Descripció">Descripció</h2> + +<p>Les instàncies <code>DataView</code> hereten de <code>DataView.prototype</code>. Com passa amb tots els constructors, podeu canviar l'objecte prototip del constructor per produir canvis a totes les instàncies <code>DataView</code>.</p> + +<h2 id="Propietats">Propietats</h2> + +<dl> + <dt>DataView.prototype.constructor</dt> + <dd>Especifica la funció que crea un prototip de l'objecte. El valor inicial és el constructor integrat estàndard <code>DataView</code>.</dd> + <dt>{{jsxref("DataView.prototype.buffer")}} {{readonlyInline}}</dt> + <dd>L'{{jsxref("ArrayBuffer")}} referenciat per aquesta vista. Fixat en el temps de construcció i per tant és <strong>només de lectura.</strong></dd> + <dt>{{jsxref("DataView.prototype.byteLength")}} {{readonlyInline}}</dt> + <dd>La llargària (en bytes) d'aquesta vista des del començament del seu {{jsxref("ArrayBuffer")}}. Fixat en el temps de construcció i per tant és <strong>només de lectura.</strong></dd> + <dt>{{jsxref("DataView.prototype.byteOffset")}} {{readonlyInline}}</dt> + <dd>La posició (en bytes) d'aquesta vista des de l'inici del seu {{jsxref("ArrayBuffer")}}. Fixat en el temps de construcció i per tant és <strong>només de lectura.</strong></dd> +</dl> + +<h2 id="Mètodes">Mètodes</h2> + +<h3 id="Lectura">Lectura</h3> + +<dl> + <dt>{{jsxref("DataView.prototype.getInt8()")}}</dt> + <dd>Obté un nombre sencer (byte) de 8 bits amb signe al byte de posició especificat des de l'inici de la vista.</dd> + <dt>{{jsxref("DataView.prototype.getUint8()")}}</dt> + <dd>Obté un nombre sencer sense signe de 8 bits (unsigned byte) al byte de posició especificat des de l'inici de la vista.</dd> + <dt>{{jsxref("DataView.prototype.getInt16()")}}</dt> + <dd>Obté un nombre sencer de 16 bits (short) al byte de posició especificat des de l'inici de la vista.</dd> + <dt>{{jsxref("DataView.prototype.getUint16()")}}</dt> + <dd>Obté un nombre sencer sense signe de 16 bits (unsigned short) al byte de posició especificat des de l'inici de la vista.</dd> + <dt>{{jsxref("DataView.prototype.getInt32()")}}</dt> + <dd>Obté un nombre sencer de 32 bits (long) al byte de posició especificat des de l'inici de la vista.</dd> + <dt>{{jsxref("DataView.prototype.getUint32()")}}</dt> + <dd>Obté un nombre sencer sense signe de 31 bits (unsigned long) al byte de posició especificat des de l'inici de la vista.</dd> + <dt>{{jsxref("DataView.prototype.getFloat32()")}}</dt> + <dd>Obté un nombre en coma flotant amb signe de 32 bits (float) al byte de posició especificat des de l'inici de la vista.</dd> + <dt>{{jsxref("DataView.prototype.getFloat64()")}}</dt> + <dd>Obté un nombre en coma flotant amb signe de 64 bits (double) al byte de posició especificat des de l'inici de la vista.</dd> +</dl> + +<h3 id="Escritura">Escritura</h3> + +<dl> + <dt>{{jsxref("DataView.prototype.setInt8()")}}</dt> + <dd>Emmagatzema el valor d'un nombre sencer de 8 bits (byte) al byte de posició especificat des de l'inici de la vista.</dd> + <dt>{{jsxref("DataView.prototype.setUint8()")}}</dt> + <dd>Emmagatzema el valor d'un nombre sencer sense signe de 8 bits (unsigned byte) al byte de posició especificat des de l'inici de la vista.</dd> + <dt>{{jsxref("DataView.prototype.setInt16()")}}</dt> + <dd>Emmagatzema el valor d'un nombre sencer amb signe de 16 bits (short) al byte de posició especificat des de l'inici de la vista.</dd> + <dt>{{jsxref("DataView.prototype.setUint16()")}}</dt> + <dd>Emmagatzema el valor d'un nombre sencer sense signe de 16 bits (unsigned short) al byte de posició especificat des de l'inici de la vista.</dd> + <dt>{{jsxref("DataView.prototype.setInt32()")}}</dt> + <dd>Emmagatzema el valor d'un nombre sencer amb signe de 32 bits (long) al byte de posició especificat des de l'inici de la vista.</dd> + <dt>{{jsxref("DataView.prototype.setUint32()")}}</dt> + <dd>Emmagatzema el valor d'un nombre sencer sense signe de 32 bits (unsigned long) al byte de posició especificat des de l'inici de la vista.</dd> + <dt>{{jsxref("DataView.prototype.setFloat32()")}}</dt> + <dd>Emmagatzema el valor d'un nombre en coma flotant amb signe de 32 bits (float) al byte de posició especificat des de l'inici de la vista.</dd> + <dt>{{jsxref("DataView.prototype.setFloat64()")}}</dt> + <dd>Emmagatzema el valor d'un nombre en coma flotant amb signe de 64 bits (double) al byte de posició especificat des de l'inici de la vista.</dd> +</dl> + +<h2 id="Especificacions">Especificacions</h2> + +<table class="standard-table"> + <tbody> + <tr> + <th scope="col">Especificació</th> + <th scope="col">Estat</th> + <th scope="col">Comentaris</th> + </tr> + <tr> + <td>{{SpecName('ES6', '#sec-dataview.prototype', 'DataView.prototype')}}</td> + <td>{{Spec2('ES6')}}</td> + <td>Definició inicial.</td> + </tr> + </tbody> +</table> + +<h2 id="Compatibilitat_amb_navegador">Compatibilitat amb navegador</h2> + +<p>{{CompatibilityTable}}</p> + +<div id="compat-desktop"> +<table class="compat-table"> + <tbody> + <tr> + <th>Característica</th> + <th>Chrome</th> + <th>Firefox (Gecko)</th> + <th>Internet Explorer</th> + <th>Opera</th> + <th>Safari</th> + </tr> + <tr> + <td>Suport bàsic</td> + <td>9.0</td> + <td>{{ CompatGeckoDesktop("15.0") }}</td> + <td>10</td> + <td>12.1</td> + <td>5.1</td> + </tr> + </tbody> +</table> +</div> + +<div id="compat-mobile"> +<table class="compat-table"> + <tbody> + <tr> + <th>Característica</th> + <th>Android</th> + <th>Chrome per Android</th> + <th>Firefox Mobile (Gecko)</th> + <th>IE Mobile</th> + <th>Opera Mobile</th> + <th>Safari Mobile</th> + </tr> + <tr> + <td>Suport bàsic</td> + <td>4.0</td> + <td>{{CompatVersionUnknown}}</td> + <td>{{CompatGeckoMobile("15")}}</td> + <td>{{CompatUnknown}}</td> + <td>12.0</td> + <td>4.2</td> + </tr> + </tbody> +</table> +</div> + +<h2 id="Vegeu_també">Vegeu també</h2> + +<ul> + <li>{{jsxref("DataView")}}</li> +</ul> |