-
-
Save OyaCanli/4516e822df6b3449775f9d0810a25d20 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@InverseMethod("positionToGender") | |
public static int genderToPosition(Gender gender){ | |
return gender == null ? 0 : gender.ordinal(); | |
} | |
public static Gender positionToGender(int position){ | |
return Gender.values()[position]; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment