`validateMask()` doesn't say the method returns anything. It implies value is validated but it's not clear it's also returned. I'd either merge it with `getCodeMask()` or rename it (`findMask()` ?).

`@throws` should go after `@return`.