แบบสำรวจการวิจัย: บอกให้เราทราบเกี่ยวกับประสบการณ์การใช้งาน Blockly
เริ่มแบบสำรวจ
blockly > CodeGenerator > INFINITE_LOOP_TRAP
พร็อพเพอร์ตี้ CodeGenerator.INFINITE_LOOP_TRAP
โค้ดที่กำหนดเองเพื่อแทรกลงในตำแหน่งที่มีความเสี่ยงที่จะก่อให้เกิดการวนซ้ำที่ไม่มีที่สิ้นสุด อินสแตนซ์ของ "%1" จะแทนที่ด้วยรหัสการบล็อกที่ล้มเหลว เช่น checkTimeout(%1);\n
ลายเซ็น:
INFINITE_LOOP_TRAP: string | null;
เนื้อหาของหน้าเว็บนี้ได้รับอนุญาตภายใต้ใบอนุญาตที่ต้องระบุที่มาของครีเอทีฟคอมมอนส์ 4.0 และตัวอย่างโค้ดได้รับอนุญาตภายใต้ใบอนุญาต Apache 2.0 เว้นแต่จะระบุไว้เป็นอย่างอื่น โปรดดูรายละเอียดที่นโยบายเว็บไซต์ Google Developers Java เป็นเครื่องหมายการค้าจดทะเบียนของ Oracle และ/หรือบริษัทในเครือ
อัปเดตล่าสุด 2024-08-21 UTC
[null,null,["อัปเดตล่าสุด 2024-08-21 UTC"],[[["`CodeGenerator.INFINITE_LOOP_TRAP` allows you to insert code snippets into potentially infinite loop-prone areas within generated code."],["This property accepts a string containing the code to inject, where '%1' is replaced with the problematic block's ID."],["The purpose is to mitigate the risk of infinite loops during code execution by introducing checks or safeguards."],["Its value can be customized as needed but defaults to `null`, implying no loop trap code injection by default."]]],[]]