代码之家  ›  专栏  ›  技术社区  ›  Axbor Axrorov

带有setInitialKey的PageKeyedDataSource

  •  0
  • Axbor Axrorov  · 技术社区  · 8 年前

    PagedList<Employee> pagedList = new PagedList.Builder<>(dataSource, config) .setMainThreadExecutor(new MainThreadExecutor()) .setBackgroundThreadExecutor(Executors.newSingleThreadExecutor()) .setInitialKey(50) .build();

    1 回复  |  直到 8 年前
        1
  •  0
  •   Axbor Axrorov    8 年前

    .setInitialKey不影响PageKeyedDataSource。即使传递值10000,PageKeyedDataSource也将调用loadInitial方法。

    推荐文章