pFad - Phone/Frame/Anonymizer/Declutterfier! Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

URL: http://developer.mozilla.org/ja/docs/Web/JavaScript/Reference/Global_Objects/Float64Array

pt>

このページはコミュニティーの尽力で英語から翻訳されました。MDN Web Docs コミュニティーについてもっと知り、仲間になるにはこちらから。

View in English Always switch to English

Float64Array

Baseline 広く利用可能

この機能は広く実装されており、多くのバージョンの端末やブラウザーで動作します。2015年7月以降、すべてのブラウザーで利用可能です。

Float64Array は型付き配列で、プラットフォームのバイト順による 64 ビット浮動小数点数の配列を表します。バイト順の制御が必要な場合は、代わりに DataView を使用してください。初期化データが明示的に指定されていない限り、内容は 0 に初期化されます。生成されると、配列内の要素はそのオブジェクトのメソッドを使用するか、配列の標準的な配列の添字構文(すなわち、ブラケット記法)を使用するかして参照することができます。

Float64Array は非公開の TypedArray クラスのサブクラスです。

コンストラクター

Float64Array()

新しい Float64Array オブジェクトを生成します。

静的プロパティ

親である TypedArray から継承した静的プロパティもあります

Float64Array.BYTES_PER_ELEMENT

要素の大きさを数値で返します。Float64Array の場合は 8 です。

静的メソッド

親である TypedArray から継承した静的メソッドがあります

インスタンスプロパティ

親である TypedArray から継承したインスタンスプロパティもあります

これらのプロパティは Float64Array.prototype で定義されており、すべての Float64Array インスタンスで共有されています。

Float64Array.prototype.BYTES_PER_ELEMENT

要素の大きさを数値で返します。Float64Array の場合は 8 です。

Float64Array.prototype.constructor

このインスタンスオブジェクトを構築したコンストラクター関数です。 Float64Array インスタンスの場合、初期値は Float64Array コンストラクターです。

インスタンスメソッド

親である TypedArray から継承したインスタンスメソッドがあります

様々な方法で Float64Array を作成

js
// 長さから
const float64 = new Float64Array(2);
float64[0] = 42;
console.log(float64[0]); // 42
console.log(float64.length); // 2
console.log(float64.BYTES_PER_ELEMENT); // 8

// 配列から
const x = new Float64Array([21, 31]);
console.log(x[1]); // 31

// 他の TypedArray から
const y = new Float64Array(x);
console.log(y[0]); // 21

// ArrayBuffer から
const buffer = new ArrayBuffer(64);
const z = new Float64Array(buffer, 8, 4);
console.log(z.byteOffset); // 8

// 反復可能オブジェクトから
const iterable = (function* () {
  yield* [1, 2, 3];
})();
const float64FromIterable = new Float64Array(iterable);
console.log(float64FromIterable);
// Float64Array [1, 2, 3]

仕様書

仕様書
ECMAScript® 2027 Language Specification
# sec-typedarray-objects

ブラウザーの互換性

関連情報

pFad - Phonifier reborn

Pfad - The Proxy pFad © 2024 Your Company Name. All rights reserved.





Check this box to remove all script contents from the fetched content.



Check this box to remove all images from the fetched content.


Check this box to remove all CSS styles from the fetched content.


Check this box to keep images inefficiently compressed and original size.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy