@ SuppressWarnings ( "unchecked" ) private static IKeyEnum getEnum ( final AnnotationData pAnnotation , final BitUtils pBit ) { int val = 0 ; try { val = Integer . parseInt ( pBit . getNextHexaString ( pAnnotation . getSize ( ) ) , pAnnotation . isReadHexa ( ) ? 16 : 10 ) ; } catch ( NumberFormatException nfe ) { // do nothing } return EnumUtils . getValue ( val , ( Class < ? extends IKeyEnum > ) pAnnotation . getField ( ) . getType ( ) ) ; }
This method is used to get an enum with his key