(pf *parquet.File, opts common.SearchOptions)
| 495 | } |
| 496 | |
| 497 | func rowGroupsFromFile(pf *parquet.File, opts common.SearchOptions) []parquet.RowGroup { |
| 498 | rgs := pf.RowGroups() |
| 499 | if opts.TotalPages > 0 { |
| 500 | // Read UP TO TotalPages. The sharding calculations |
| 501 | // are just estimates, so it may not line up with the |
| 502 | // actual number of pages in this file. |
| 503 | if opts.StartPage+opts.TotalPages > len(rgs) { |
| 504 | opts.TotalPages = len(rgs) - opts.StartPage |
| 505 | } |
| 506 | rgs = rgs[opts.StartPage : opts.StartPage+opts.TotalPages] |
| 507 | } |
| 508 | |
| 509 | return rgs |
| 510 | } |
no outgoing calls
no test coverage detected