Survei Riset: Ceritakan pengalaman Anda dengan Blockly
Mulai survei
blockly > ASTNode > getSourceBlock
Metode ASTNode.getSourceBlock()
Menemukan blok sumber lokasi node ini.
Tanda Tangan:
getSourceBlock(): Block | null;
Hasil:
Block | null
Blok sumber lokasi, atau null jika node berjenis ruang kerja atau tombol.
Kecuali dinyatakan lain, konten di halaman ini dilisensikan berdasarkan Lisensi Creative Commons Attribution 4.0, sedangkan contoh kode dilisensikan berdasarkan Lisensi Apache 2.0. Untuk mengetahui informasi selengkapnya, lihat Kebijakan Situs Google Developers. Java adalah merek dagang terdaftar dari Oracle dan/atau afiliasinya.
Terakhir diperbarui pada 2024-11-08 UTC.
[null,null,["Terakhir diperbarui pada 2024-11-08 UTC."],[[["The `ASTNode.getSourceBlock()` method helps locate the original block associated with a given AST node."],["This method returns the source block itself, or null if the node corresponds to the workspace or a button."],["Primarily used for tracing back from an abstract syntax tree node to its visual representation in Blockly."]]],[]]