@class NSDictionary, NSHashTable, PXLibraryFilterState, PXLIFOQueue, NSMutableArray, NSString, NSMutableSet, NSArray, NSMutableDictionary, PHAsset, PHFetchResult, PHPhotoLibrary, NSPredicate, PXPhotosDataSourceSectionCache, NSObject, NSSet, PXPhotosAssetsFetcher, PXSharedLibraryStatusProvider, PHAssetCollection, PHCollection, NSMutableOrderedSet, NSNumber, PXBackgroundFetchToken; @protocol OS_dispatch_group, OS_dispatch_queue, OS_os_log; @interface PXPhotosDataSource : NSObject <PXPhotoLibraryUIChangeObserver, PXChangeObserver> { NSObject<OS_dispatch_queue> *_observersQueue; BOOL _observersQueue_shouldCopyChangeObserversOnWrite; NSHashTable *_observersQueue_observers; PXPhotosDataSourceSectionCache *__sectionCache; PXPhotosDataSourceSectionCache *__preparedSectionCache; NSDictionary *_hintIndexPathByAssetReferenceCache; NSDictionary *_preparedIndexPathByAssetReferenceCache; NSDictionary *_preparedResultRecordChangeDetailsByAssetCollection; NSMutableDictionary *_resultRecordByAssetCollection; NSMutableSet *__inaccurateAssetCollections; BOOL _inaccurateAssetCollectionsNeedsUpdate; NSMutableDictionary *_preparedChangeDetailsByAssetCollection; NSMutableDictionary *_infoForAssetCollection; BOOL _backgroundFetchOriginSectionChanged; BOOL _needToStartBackgroundFetch; BOOL _didFinishBackgroundFetch; PXBackgroundFetchToken *_backgroundFetchToken; BOOL _interruptBackgroundFetch; BOOL _pauseBackgroundFetchResultsDelivery; NSMutableSet *_pauseLibraryChangeDeliveryTokens; _Atomic int _backgroundFetchId; NSMutableDictionary *_pendingResultsByAssetCollection; NSMutableDictionary *_pendingPreparedResultRecordByAssetCollection; NSObject<OS_dispatch_queue> *_pendingResultsIsolationQueue; BOOL _processAndPublishScheduledOnRunloop; NSObject<OS_dispatch_queue> *_backgroundQueue; PXLIFOQueue *_backgroundLIFOQueue; NSMutableOrderedSet *_queuedAssetCollectionsToFetch; NSObject<OS_dispatch_queue> *_prefetchQueue; NSMutableDictionary *_facesByAssetCache; NSMutableDictionary *_weightByAssetCache; BOOL _hideHiddenAssets; NSArray *_fetchPropertySets; long long _curationType; PHFetchResult *_emptyAssetsFetchResult; NSNumber *_cachedIsEmpty; long long _nestedChanges; long long _nestedCoalesceChanges; NSMutableArray *_coalescedChanges; PXPhotosDataSource *_parentDataSource; } @property (class, readonly, nonatomic) NSObject<OS_dispatch_group> *backgroundFetchingGroup; @property (nonatomic, setter=_setPreviousCollectionsCount:) unsigned long long _previousCollectionsCount; @property (nonatomic) BOOL isBackgroundFetching; @property (readonly, nonatomic) NSObject<OS_dispatch_queue> *clientQueue; @property (readonly, nonatomic) PXPhotosAssetsFetcher *fetcher; @property (readonly, nonatomic) NSObject<OS_os_log> *dataSourceLog; @property (nonatomic) unsigned long long signpostIntervalId; @property (readonly, nonatomic) PXSharedLibraryStatusProvider *sharedLibraryStatusProvider; @property (readonly, nonatomic) PXLibraryFilterState *libraryFilterState; @property (nonatomic) BOOL allowNextChangeDeliveryOnAllRunLoopModes; @property (nonatomic) BOOL allowSlowFetchesOnClientQueue; @property (readonly, nonatomic) BOOL wantsCurationForFirstAssetCollection; @property (readonly, nonatomic) unsigned long long options; @property (readonly, nonatomic) PHPhotoLibrary *photoLibrary; @property (readonly, nonatomic) long long versionIdentifier; @property (retain, nonatomic) PHFetchResult *collectionListFetchResult; @property (readonly, nonatomic) PHCollection *containerCollection; @property (readonly, nonatomic) PHAssetCollection *containerAssetCollection; @property (readonly, nonatomic) PHAsset *referenceAsset; @property (readonly, nonatomic) NSArray *filterPersons; @property (readonly, nonatomic) BOOL isImmutable; @property (readonly, nonatomic) BOOL isEmpty; @property (readonly, nonatomic) BOOL containsMultipleAssets; @property (readonly, nonatomic) BOOL supportsCurationToggling; @property (readonly, nonatomic) long long estimatedPhotosCount; @property (readonly, nonatomic) long long estimatedVideosCount; @property (readonly, nonatomic) long long estimatedOtherCount; @property (readonly, nonatomic) BOOL areAllSectionsConsideredAccurate; @property (nonatomic) long long backgroundFetchOriginSection; @property (readonly, nonatomic) NSPredicate *basePredicate; @property (retain, nonatomic) NSPredicate *filterPredicate; @property (nonatomic) BOOL ignoreSharedLibraryFilters; @property (nonatomic) long long libraryFilter; @property (nonatomic) BOOL canIncludeUnsavedSyndicatedAssets; @property (copy, nonatomic) NSSet *allowedUUIDs; @property (copy, nonatomic) NSSet *allowedOIDs; @property (nonatomic) unsigned long long fetchLimit; @property (copy, nonatomic) NSArray *sortDescriptors; @property (nonatomic) BOOL reverseSortOrder; @property (nonatomic) BOOL wantsCurationByDefault; @property (readonly) unsigned long long hash; @property (readonly) Class superclass; @property (readonly, copy) NSString *description; @property (readonly, copy) NSString *debugDescription; + (id)_curationSharedBackgroundQueue; + (id)_sharedPrefetchQueue; + (void)waitForAllBackgroundFetchingToFinish; - (id)assetReferenceAtIndexPath:(id)a0; - (id)assetsInSection:(long long)a0; - (void)clearResultsForAssetCollections:(id)a0; - (id)assetCollectionForSection:(long long)a0; - (void)performChanges:(id /* block */)a0; - (void)resumeChangeDeliveryAndBackgroundLoading:(id)a0; - (void)prefetchApproximateAssetsAtIndexPaths:(id)a0; - (void)stopExcludingAssets:(id)a0; - (id)_inaccurateAssetCollections; - (BOOL)_areFiltersDisabledForAssetCollection:(id)a0; - (id)_closestIndexPathToIndexPath:(id)a0; - (id)indexPathForAssetWithUUID:(id)a0 orSyndicationIdentifier:(id)a1 hintIndexPath:(id)a2 hintCollection:(id)a3; - (void)registerChangeObserver:(id)a0; - (void)startBackgroundFetchIfNeeded; - (void)_processAndPublishPendingCollectionFetchResultsWhenAppropriate; - (id)fetchResultWithAssetsInSections:(id)a0; - (void)observable:(id)a0 didChange:(unsigned long long)a1 context:(void *)a2; - (void)dealloc; - (void)forceIncludeAssetsAtIndexPaths:(id)a0; - (id)_assetsForAssetCollection:(id)a0; - (void)forceExcludeAssetsAtIndexes:(id)a0; - (void)setKeyAsset:(id)a0 forAssetCollection:(id)a1; - (id)indexPathForAssetWithUUID:(id)a0 orBurstIdentifier:(id)a1 hintIndexPath:(id)a2 hintCollection:(id)a3; - (void)stopForceIncludingAllAssets; - (BOOL)_forceAccurateSection:(long long)a0 andNumberOfSurroundingSectionsWithContent:(long long)a1; - (void)unregisterChangeObserver:(id)a0; - (id)_allowedOIDsForAssetCollection:(id)a0; - (id)_mutableResultRecordForAssetCollection:(id)a0; - (void)photoLibraryDidChangeOnMainQueue:(id)a0; - (void)forceExcludeAssetsAtIndexPaths:(id)a0; - (id)lastAssetCollection; - (id)_finalFilterPredicateForAssetCollection:(id)a0; - (void)pauseChangeDeliveryFor:(double)a0 identifier:(id)a1; - (void)_willChange; - (void)clearResultsForAssetCollection:(id)a0; - (void)_performManualChangesForAssetCollections:(id)a0 collectionsToDiff:(id)a1 collectionsToChange:(id)a2 changeBlock:(id /* block */)a3; - (void)_publishReloadChange; - (void)_endFilterPredicateChangedForCollection:(id)a0; - (void)_performProcessAndPublishSelectorInDefaultRunLoopMode; - (long long)indexForAsset:(id)a0 inCollection:(id)a1 hintIndex:(long long)a2; - (id)_inclusionPredicateForAssetCollection:(id)a0; - (unsigned long long)_assetCollectionFetchStatus:(id)a0; - (id)indexPathForAssetReference:(id)a0; - (id)_allowedUUIDsForAssetCollection:(id)a0; - (BOOL)forceAccurateIndexPath:(id)a0 andAssetsBeforeAndAfter:(long long)a1; - (void)setWantsCurationForAllCollections:(BOOL)a0 collectionsToDiff:(id)a1; - (id)curatedAssetsInSection:(long long)a0; - (id)_filterPredicateForAssetCollection:(id)a0; - (void)_updateInaccurateAssetCollectionsIfNeeded; - (id)assetAtIndexPath:(id)a0; - (id)_assetOidsByAssetCollectionForAssetsAtIndexPathsInSet:(id)a0; - (id)createDataSourceWithAssetsAtIndexPaths:(id)a0; - (id)approximateAssetsAtIndexPaths:(id)a0; - (BOOL)wantsCurationForAssetCollection:(id)a0; - (id)indexPathForFirstAsset; - (long long)numberOfItemsInSection:(long long)a0; - (id)_resultRecordForAssetCollection:(id)a0; - (id)immutableCopy; - (void)_cancelBackgroundFetchIfNeeded; - (id)_createDataSourceWithAssetsCollections:(id)a0; - (void)_interruptBackgroundFetch; - (void)_distributeChange:(id)a0; - (id)facesAtSimpleIndexPath:(struct PXSimpleIndexPath { long long x0; long long x1; long long x2; long long x3; })a0; - (id)keyAssetsInSection:(long long)a0; - (void)_performManualChangesForAssetCollections:(id)a0 collectionsToDiff:(id)a1 changeBlock:(id /* block */)a2; - (id)uncuratedAssetsForAssetCollection:(id)a0; - (void)_performManualReloadWithChangeBlock:(id /* block */)a0; - (BOOL)hasCurationForAssetCollection:(id)a0; - (BOOL)isCuratedAssetsFutilelyForAssetCollection:(id)a0; - (id)_fetchAssetsStartingAtIndexPath:(id)a0; - (void)prefetchApproximateAssetsAtIndexPaths:(id)a0 reverseOrder:(BOOL)a1; - (long long)_nextBackgroundFetchId; - (BOOL)_areSecondaryFetchesEnabled; - (id)_fetchTupleForAssetCollection:(id)a0 calledOnClientQueue:(BOOL)a1 isLimitedInitialFetch:(BOOL)a2; - (BOOL)forceAccurateAssetCollectionsIfNeeded:(id)a0 reloadChanges:(BOOL)a1; - (id)createDataSourceWithAssetsInSectionOfAsset:(id)a0; - (id)indexPathForAsset:(id)a0 inCollection:(id)a1; - (void)_bringFetchResultsUpToDateWithFetcherCacheForAssetCollection:(id)a0; - (id)initWithPhotosDataSourceConfiguration:(id)a0; - (void)_publishDidReceivePhotoLibraryChange:(id)a0; - (BOOL)_allSectionsConsideredAccurate; - (void)prefetchAssetsAtIndexPaths:(id)a0 onlyThumbnailAssets:(BOOL)a1; - (void)_startLibraryFilterChangedSignpostForCollection:(id)a0; - (void)_didChange:(id)a0; - (void)_getFetchLimit:(unsigned long long *)a0 fetchWithReverseSortOrder:(BOOL *)a1 forAssetCollection:(id)a2 isLimitedInitialFetch:(BOOL)a3; - (long long)numberOfSections; - (id)indexPathForAsset:(id)a0 hintIndexPath:(id)a1 hintCollection:(id)a2; - (unsigned long long)sectionForAssetCollection:(id)a0; - (double)weightForAsset:(id)a0; - (void).cxx_destruct; - (void)_didFinishBackgroundFetchingForId:(long long)a0; - (BOOL)_reverseSortOrderForAssetCollection:(id)a0; - (void)_restartBackgroundFetchWithAssetCollectionsToDiff:(id)a0; - (BOOL)forceAccurateSectionsIfNeeded:(id)a0; - (void)forceIncludeAssetsAtIndexes:(id)a0; - (BOOL)forceAccurateSectionsIfNeeded:(id)a0 reloadChanges:(BOOL)a1; - (id)pauseChangeDeliveryAndBackgroundLoadingWithTimeout:(double)a0 identifier:(id)a1; - (BOOL)_isResulTupleApplicable:(id)a0 forAssetCollection:(id)a1; - (id)_keyAssetsForAssetCollection:(id)a0; - (void)_enumerateChangeObserversWithBlock:(id /* block */)a0; - (id)initWithPhotosDataSource:(id)a0 options:(unsigned long long)a1; - (id)assetsStartingAtIndexPath:(id)a0; - (BOOL)supportsDynamicBackgroundFetching; - (id)assetsAtIndexPaths:(id)a0; - (void)_processAndPublishPendingCollectionFetchResults; - (BOOL)forceAccurateAllSectionsIfNeeded; - (BOOL)forceAccurateSection:(long long)a0 andSectionsBeforeAndAfter:(long long)a1; - (id)uncuratedAssetsInSection:(long long)a0; - (void)_internalSetLibraryFilter:(long long)a0; - (BOOL)_addResultTuple:(id)a0 forAssetCollection:(id)a1 preparedResultRecord:(id)a2 toMutableResultRecord:(id)a3; - (id)_sectionCache; - (id)infoForAssetCollection:(id)a0; - (void)_endLibraryFilterChangedSignpostForCollection:(id)a0; - (long long)estimatedAssetsCountWithEnrichmentState:(unsigned short)a0; - (void)refetchResultsForAssetCollection:(id)a0; - (id)_createResultRecordForAssetCollection:(id)a0; - (void)_initResultRecordsWithOldOptions:(unsigned long long)a0 newOptions:(unsigned long long)a1; - (id)_observerInterestingAssetReferences; - (void)_prepareDiffsForPendingResultsWithCompletion:(id /* block */)a0; - (id)fetchResultWithAssetsAtIndexPaths:(id)a0; - (void)setDisableFilters:(BOOL)a0 forAssetCollection:(id)a1; - (BOOL)_isFiltering; - (void)setFilterPredicate:(id)a0 provideIncrementalChangeDetailsForAssetCollections:(id)a1; - (long long)keyAssetIndexInSection:(long long)a0; - (BOOL)isCuratedAssetsEmptyForAssetCollection:(id)a0; - (id)assetAtSimpleIndexPath:(struct PXSimpleIndexPath { long long x0; long long x1; long long x2; long long x3; })a0; - (void)enumerateStartingAtIndexPath:(id)a0 reverseDirection:(BOOL)a1 usingBlock:(id /* block */)a2; - (void)_fetchRemainingCollectionsBackgroundLoopWithId:(long long)a0; - (void)_childDataSourceDidUpdateFetchesForAssetCollection:(id)a0; - (unsigned long long)_cachedSectionForAssetCollection:(id)a0; - (BOOL)isAssetAtIndexPathPartOfCuratedSet:(struct PXSimpleIndexPath { long long x0; long long x1; long long x2; long long x3; })a0; - (id)assetReferenceForAsset:(id)a0 containedInAssetCollectionWithType:(long long)a1; - (id)prepareForPhotoLibraryChange:(id)a0; - (id)indexPathForLastAsset; - (id)fetchResultsByAssetCollection; - (id)firstAssetCollection; - (id)_indexPathForAssetWithUUID:(id)a0 orBurstIdentifier:(id)a1 orSyndicationIdentifier:(id)a2 hintIndexPath:(id)a3 hintCollections:(id)a4; - (void)_commonInit; - (id)curatedAssetsForAssetCollection:(id)a0; - (void)_startFilterPredicateChangedSignpostForCollection:(id)a0; - (id)sectionsForAssetCollections:(id)a0; - (void)_observersQueue_copyChangeObserversForWriteIfNeeded; - (void)setWantsCuration:(BOOL)a0 forAssetCollection:(id)a1; - (void)prefetchAssetsInSections:(id)a0; - (long long)numberOfSectionsWithEnrichmentState:(unsigned short)a0; - (void)_performManualChangesForAssetCollections:(id)a0 changeBlock:(id /* block */)a1; - (void)_incrementVersionIdentifier; - (id)indexPathForAsset:(id)a0 hintIndexPath:(id)a1 hintCollections:(id)a2; - (void)_prefetchIndexesByFetchResult:(id)a0 onlyThumbnails:(BOOL)a1; @end