Binding vs Polymorphism

736 views Asked by At

Is there any direct relationship between Late Binding and Overriding, similarly for Early Binding and Overloading?

They (Binding/Overriding/Overloading) can be termed as ways to implement polymorphism, but is there any "Direct Relationship" ex: Late Binding is a sub/super concept to Overriding and vice versa etc?

1

There are 1 answers

3
dario_ramos On BEST ANSWER

They are orthogonal (independent) concepts.

  • Overloading, Overriding: Forms of polymorphism
  • Early binding/Late binding: In the former, the method to call is known at compile time. In the latter, at runtime.

Of course, an implementation of overriding usually implies using late binding, because you will only know the object's real type at runtime. But that's just a special case.