Survei Riset: Ceritakan pengalaman Anda dengan Blockly
Mulai survei
Tetap teratur dengan koleksi
Simpan dan kategorikan konten berdasarkan preferensi Anda.
blockly > ConnectionDB > removeConnection
Metode ConnectionDB.removeConnection()
Menghapus koneksi dari database. Harus sudah ada di DB.
Tanda Tangan:
removeConnection(connection: RenderedConnection, yPos: number): void;
Parameter
Parameter |
Jenis |
Deskripsi |
koneksi |
RenderedConnection |
Koneksi yang akan dihapus. |
yPos |
angka |
Posisi y yang digunakan untuk menemukan indeks koneksi. |
Hasil:
void
Pengecualian
{Error} Jika koneksi tidak dapat ditemukan dalam database.
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-10-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 2024-10-16 UTC."],[[["The `removeConnection` method is used to remove a specific connection from the ConnectionDB."],["In order to remove a connection, it must already exist in the database."],["To use this method, you must provide the `RenderedConnection` object and its y position (`yPos`) for database lookup."],["If the provided connection is not found in the database, it will throw an error."]]],["The `removeConnection` method within the `ConnectionDB` class removes a specified `RenderedConnection` from the database. It requires the connection to exist and uses a `yPos` number to locate its index. The method takes the connection and its y-position as parameters. Upon successful removal, the method returns void. An error is thrown if the connection cannot be found.\n"]]