調査アンケート: Blockly のご利用体験についてお聞かせください
アンケートを開始
コレクションでコンテンツを整理
必要に応じて、コンテンツの保存と分類を行います。
ブロックする >接続 >getShadowDom
Connection.getShadowDom() メソッド
接続のシャドウ ブロックの XML 表現を返します。
署名:
getShadowDom(returnCurrent?: boolean): Element | null;
パラメータ
パラメータ |
型 |
説明 |
returnCurrent |
ブール値 |
(省略可)true で、シャドウ ブロックが現在この接続に接続されている場合、そのブロックの状態がシリアル化されて返されます(これにより、フィールド値が正しいようになります)。それ以外の場合は、保存された shadowDom が返されます。 |
戻り値:
要素 |null
ブロックまたは null の Shadow DOM 表現。
特に記載のない限り、このページのコンテンツはクリエイティブ・コモンズの表示 4.0 ライセンスにより使用許諾されます。コードサンプルは Apache 2.0 ライセンスにより使用許諾されます。詳しくは、Google Developers サイトのポリシーをご覧ください。Java は Oracle および関連会社の登録商標です。
最終更新日 2025-07-25 UTC。
[[["わかりやすい","easyToUnderstand","thumb-up"],["問題の解決に役立った","solvedMyProblem","thumb-up"],["その他","otherUp","thumb-up"]],[["必要な情報がない","missingTheInformationINeed","thumb-down"],["複雑すぎる / 手順が多すぎる","tooComplicatedTooManySteps","thumb-down"],["最新ではない","outOfDate","thumb-down"],["翻訳に関する問題","translationIssue","thumb-down"],["サンプル / コードに問題がある","samplesCodeIssue","thumb-down"],["その他","otherDown","thumb-down"]],["最終更新日 2025-07-25 UTC。"],[[["The `Connection.getShadowDom()` method returns the XML representation of a connection's shadow block, which is used to store and manage the block's structure and data."],["You can optionally pass `returnCurrent: true` to get the serialized state of the currently attached shadow block, ensuring field values are up-to-date; otherwise, the saved shadow DOM is returned."],["The method returns an `Element` containing the shadow DOM, or `null` if no shadow DOM is associated with the connection."]]],[]]