Specifies that the field value is a compile - time constant 指定该字段值是一个编译时常数。
Field is a compile - time constant , the 字段为编译时常数,而
Compile - time constants are required for cases such as array bounds , case expressions , or enumerator initializers 需要编译时常数的情况包括数组界限、 case表达式或枚举数初始值设定项。
A compile - time constant will have the same value each time an application runs , while a run - time constant may change each time 应用程序每次运行时,编译时常数都具有相同的值,而运行时常数的值可能会发生变化。
A compile - time constant is computed at the time the code is compiled , while a run - time constant can only be computed while the application is running 编译时常数和运行时常数编译时常数在编译代码时进行计算,而运行时常数则只能在应用程序运行时进行计算。