public static GroupType listOfElements ( Repetition listRepetition , String name , Type elementType ) { Preconditions . checkArgument ( elementType . getName ( ) . equals ( ELEMENT_NAME ) , "List element type must be named 'element'" ) ; return listWrapper ( listRepetition , name , LogicalTypeAnnotation . listType ( ) , new GroupType ( Repetition . REPEATED , "list" , elementType ) ) ; }
Creates a 3 - level list structure annotated with LIST with elements of the given elementType . The repeated level is inserted automatically and the elementType s repetition should be the correct repetition of the elements required for non - null and optional for nullable .