PIbd-21_Markov_D.P._Contain.../AdditionalEnum.java
2022-12-01 23:30:57 +04:00

25 lines
447 B
Java

public enum AdditionalEnum {
One,
Two,
Three;
public static AdditionalEnum FromInteger(int intValue)
{
switch(intValue)
{
case 1:
return One;
case 2:
return Two;
case 3:
return Three;
default:
System.out.println("Error: incorrect value for enum");
return null;
}
}
}