Marker Interfaces

前端 未结 6 1861
萌比男神i
萌比男神i 2021-01-18 08:42

Could somebody pls explain the contract of marker interfaces in java?

For Ex: If Clonable is a Marker Interface with no fields/methods, then where is t

6条回答
  •  粉色の甜心
    2021-01-18 08:56

    Marker interfaces do not have any body as such.They just ask java interpreter to behave in a predefined particular way for objects of classes extending them.

提交回复
热议问题