Late binding(晚期绑定/后期绑定):指在程序运行时(而不是编译时)才决定要调用哪个函数/方法、使用哪个实现或解析哪个符号的机制。常见于动态语言、反射、虚函数/多态以及某些组件技术(如 COM 自动化)中。也可泛指“把决定推迟到最后一刻”的绑定策略。
Late binding lets the program decide which method to call at runtime.
晚期绑定让程序在运行时决定调用哪个方法。
In a plugin-based system, late binding can improve extensibility, but it may also hide errors until the code is executed.
在基于插件的系统中,晚期绑定可以提升可扩展性,但也可能把错误隐藏到代码真正执行时才暴露。
/ˈleɪt ˈbaɪndɪŋ/
late 意为“较晚的、在后面的”,binding 来自动词 bind(“绑定、捆绑、约束”),在计算机语境中引申为“把名称与具体实现/地址/类型等对应起来”。合起来 late binding 即“较晚发生的绑定”,强调“推迟到运行阶段再决定”。