Survei Riset: Ceritakan pengalaman Anda dengan Blockly
Mulai survei
Tetap teratur dengan koleksi
Simpan dan kategorikan konten berdasarkan preferensi Anda.
blockly > Connection
Class koneksi
Class untuk koneksi antar-blok.
Tanda Tangan:
export declare class Connection
Konstruktor
Properti
Metode
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 2025-05-16 UTC.
[[["Mudah dipahami","easyToUnderstand","thumb-up"],["Memecahkan masalah saya","solvedMyProblem","thumb-up"],["Lainnya","otherUp","thumb-up"]],[["Informasi yang saya butuhkan tidak ada","missingTheInformationINeed","thumb-down"],["Terlalu rumit/langkahnya terlalu banyak","tooComplicatedTooManySteps","thumb-down"],["Sudah usang","outOfDate","thumb-down"],["Masalah terjemahan","translationIssue","thumb-down"],["Masalah kode / contoh","samplesCodeIssue","thumb-down"],["Lainnya","otherDown","thumb-down"]],["Terakhir diperbarui pada 2025-05-16 UTC."],[[["The `Connection` class in Blockly manages connections between blocks, enabling them to link and interact."],["It provides methods for connecting, disconnecting, and checking compatibility between connections."],["Connections have properties like `type` and `targetConnection` to define their role and relationships."],["`Connection` includes functionality for managing shadow blocks, which provide placeholders or default values."],["Developers can use methods like `getCheck`, `setCheck`, and `isConnected` to control and query connection states."]]],["The `Connection` class manages connections between blocks. Key actions include: connecting (`connect`, `connect_`), disconnecting (`disconnect`, `disconnectInternal`) and reconnecting blocks (`reconnect`). It manages connection compatibility (`getCheck`, `setCheck`), determines connection status (`isConnected`, `isSuperior`), and provides methods to manage shadow blocks (`getShadowDom`, `setShadowDom`, `respawnShadow_`). The class also defines constants for connection compatibility checks, providing reason codes. Methods exist to get block targets (`targetBlock`, `getSourceBlock`).\n"]]