private QrCode . Mode updateModeLogic ( QrCode . Mode current , QrCode . Mode candidate ) { if ( current == candidate ) return current ; else if ( current == QrCode . Mode . UNKNOWN ) { return candidate ; } else { return QrCode . Mode . MIXED ; } }
If only one mode then that mode is used . If more than one mode is used then set to multiple