protected List < E > createBulkLeafNodes ( List < E > objects ) { int minEntries = leafMinimum ; int maxEntries = leafCapacity ; ArrayList < E > result = new ArrayList <> ( ) ; List < List < E > > partitions = settings . bulkSplitter . partition ( objects , minEntries , maxEntries ) ; for ( List < E > partition : partitions ) { // create leaf node N leafNode = createNewLeafNode ( ) ; // insert data for ( E o : partition ) { leafNode . addLeafEntry ( o ) ; } // write to file writeNode ( leafNode ) ; result . add ( createNewDirectoryEntry ( leafNode ) ) ; if ( getLogger ( ) . isDebugging ( ) ) { getLogger ( ) . debugFine ( "Created leaf page " + leafNode . getPageID ( ) ) ; } } if ( getLogger ( ) . isDebugging ( ) ) { getLogger ( ) . debugFine ( "numDataPages = " + result . size ( ) ) ; } return result ; }
Creates and returns the leaf nodes for bulk load .