空abstract class是非常相当于interface除了它可以扩展aclass
abstract class myAbstractClass // extends anotherClass implements anInterface
{
}
interface myInterface // extends anotherInterface
{
}
Run Code Online (Sandbox Code Playgroud)
这种模式称为Marker接口,SO已经有很多关于它的好数据:标记接口的目的是什么?
| 归档时间: |
|
| 查看次数: |
3821 次 |
| 最近记录: |