Searched refs:optimizeInfo (Results 1 – 8 of 8) sorted by relevance
34 GetOptimizeInfoResultProto optimizeInfo = in testShouldOptimize_byteThreshold() local42 assertThat(mFrameworkOptimizeStrategy.shouldOptimize(optimizeInfo)).isTrue(); in testShouldOptimize_byteThreshold()47 GetOptimizeInfoResultProto optimizeInfo = in testShouldNotOptimize_timeThreshold() local55 assertThat(mFrameworkOptimizeStrategy.shouldOptimize(optimizeInfo)).isTrue(); in testShouldNotOptimize_timeThreshold()60 GetOptimizeInfoResultProto optimizeInfo = in testShouldOptimize_docCountThreshold() local68 assertThat(mFrameworkOptimizeStrategy.shouldOptimize(optimizeInfo)).isTrue(); in testShouldOptimize_docCountThreshold()
64 private static final OptimizeStrategy ALWAYS_OPTIMIZE = optimizeInfo -> true;
40 public boolean shouldOptimize(@NonNull GetOptimizeInfoResultProto optimizeInfo) { in shouldOptimize() argument41 return optimizeInfo.getOptimizableDocs() in shouldOptimize()43 || optimizeInfo.getEstimatedOptimizableBytes() in shouldOptimize()45 || optimizeInfo.getTimeSinceLastOptimizeMs() in shouldOptimize()
38 boolean shouldOptimize(@NonNull GetOptimizeInfoResultProto optimizeInfo); in shouldOptimize() argument
2216 GetOptimizeInfoResultProto optimizeInfo = getOptimizeInfoResultLocked(); in checkForOptimize() local2217 checkSuccess(optimizeInfo.getStatus()); in checkForOptimize()2219 if (mOptimizeStrategy.shouldOptimize(optimizeInfo)) { in checkForOptimize()
84 private static final OptimizeStrategy ALWAYS_OPTIMIZE = optimizeInfo -> true;451 GetOptimizeInfoResultProto optimizeInfo = mAppSearchImpl.getOptimizeInfoResultLocked(); in testTriggerCheckOptimizeByMutationSize() local452 assertThat(optimizeInfo.getOptimizableDocs()).isEqualTo(1); in testTriggerCheckOptimizeByMutationSize()459 optimizeInfo = mAppSearchImpl.getOptimizeInfoResultLocked(); in testTriggerCheckOptimizeByMutationSize()460 assertThat(optimizeInfo.getOptimizableDocs()).isEqualTo(1); in testTriggerCheckOptimizeByMutationSize()467 optimizeInfo = mAppSearchImpl.getOptimizeInfoResultLocked(); in testTriggerCheckOptimizeByMutationSize()468 assertThat(optimizeInfo.getOptimizableDocs()).isEqualTo(0); in testTriggerCheckOptimizeByMutationSize()469 assertThat(optimizeInfo.getEstimatedOptimizableBytes()).isEqualTo(0); in testTriggerCheckOptimizeByMutationSize()
66 private static final OptimizeStrategy ALWAYS_OPTIMIZE = optimizeInfo -> true;
62 private static final OptimizeStrategy ALWAYS_OPTIMIZE = optimizeInfo -> true;