Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
双重调度和访客模式之间有什么区别吗?
我正在使用 Java 和 C++,想知道两者之间是否存在分歧。
访问者模式是一种向现有类添加新操作的方法。双分派是一种针对两个(或广义上的更多)多态类型而不是单个多态类型来分派函数调用的方法,这是 C++ 和 Java 等语言直接支持的。