Java学习笔记——final

修饰变量——常量,只能被初始化一次,不可更改

修饰方法——可被子类重载,不可被子类重写

修饰类——不可被继承

猜你喜欢

转载自www.cnblogs.com/dis-board/p/9048488.html
今日推荐