我有这个枚举:
public class RemoteUnitType implements Serializable {
public enum deviceVersion {
ANDROID_AT1,
ANDROID_AT1_PRO,
ANDROID_AT5,
ANDROID_AK1
}
我想创建一个枚举开关,就像这样:
switch (remoteUnit.getDeviceVersion()) {
case RemoteUnitType.deviceVersion.ANDROID_AK1 :
break;
}
但是我收到了这个错误:
The qualified case label RemoteUnitType.deviceVersion.ANDROID_AK1 must be replaced with the unqualified enum constant