private static void createLikelySubtags ( TypeSpec . Builder type , Map < String , String > likelySubtags ) { MethodSpec . Builder method = MethodSpec . methodBuilder ( "registerLikelySubtags" ) . addModifiers ( PRIVATE , STATIC ) ; for ( Map . Entry < String , String > entry : likelySubtags . entrySet ( ) ) { method . addStatement ( "LIKELY_SUBTAGS_MAP.put($T.parse($S), $T.parse($S))" , META_LOCALE , entry . getKey ( ) , META_LOCALE , entry . getValue ( ) ) ; } type . addMethod ( method . build ( ) ) ; }
Create likely subtags mapping .