Variables in Interface

前端 未结 5 1986
长情又很酷
长情又很酷 2020-12-11 02:05

Why is that a variable used in an Interface is PUBLIC STATIC FINAL? Why \"static\" in particular?

5条回答
  •  小蘑菇
    小蘑菇 (楼主)
    2020-12-11 02:36

    Why wouldn't it be static?

    It's a constant associated with the interface, rather than with any particular instance of it.

提交回复
热议问题