Home
last modified time | relevance | path

Searched refs:CloseableReentrantLock (Results 1 – 6 of 6) sorted by relevance

/packages/providers/MediaProvider/src/com/android/providers/media/photopicker/sync/
DPickerSyncLockManager.java48 private final CloseableReentrantLock mCloudSyncLock =
49 new CloseableReentrantLock("CLOUD_SYNC_LOCK");
50 private final CloseableReentrantLock mCloudAlbumSyncLock =
51 new CloseableReentrantLock("CLOUD_ALBUM_SYNC_LOCK");
52 private final CloseableReentrantLock mCloudProviderLock =
53 new CloseableReentrantLock("CLOUD_PROVIDER_LOCK");
54 private final CloseableReentrantLock mDbCloudLock =
55 new CloseableReentrantLock("DB_CLOUD_LOCK");
60 public CloseableReentrantLock tryLock(@LockType int lockType) in tryLock()
68 public CloseableReentrantLock tryLock(@LockType int lockType, long timeout, TimeUnit unit) in tryLock()
[all …]
DCloseableReentrantLock.java31 public class CloseableReentrantLock extends ReentrantLock implements AutoCloseable { class
32 private static final String TAG = CloseableReentrantLock.class.getSimpleName();
35 public CloseableReentrantLock(@NonNull String lockName) { in CloseableReentrantLock() method in CloseableReentrantLock
43 public CloseableReentrantLock lockWithTimeout(long timeout, TimeUnit unit) in lockWithTimeout()
DMediaResetWorker.java125 try (CloseableReentrantLock ignored = pickerSyncLockManager in doWork()
/packages/providers/MediaProvider/tests/src/com/android/providers/media/photopicker/sync/
DPickerSyncLockManagerTest.java46 try (CloseableReentrantLock lock = mSyncLockManager.lock(CLOUD_SYNC_LOCK)) { in testLockIsCloseable()
51 try (CloseableReentrantLock lockInLock = mSyncLockManager.lock(CLOUD_SYNC_LOCK)) { in testLockIsCloseable()
70 try (CloseableReentrantLock lock = mSyncLockManager.tryLock(CLOUD_ALBUM_SYNC_LOCK)) { in testLockWithTimeoutIsCloseable()
75 try (CloseableReentrantLock lockInLock = in testLockWithTimeoutIsCloseable()
96 CloseableReentrantLock lock = new CloseableReentrantLock("testLock"); in testLockTimeout()
97 try (CloseableReentrantLock ignored = in testLockTimeout()
111 try (CloseableReentrantLock ignored = in testLockTimeout()
124 private void acquireLock(Handler handler, CloseableReentrantLock lock) in acquireLock()
130 private void releaseLock(Handler handler, CloseableReentrantLock lock) in releaseLock()
/packages/providers/MediaProvider/src/com/android/providers/media/photopicker/
DPickerSyncController.java70 import com.android.providers.media.photopicker.sync.CloseableReentrantLock;
238 try (CloseableReentrantLock ignored = mPickerSyncLockManager in initCloudProvider()
311 try (CloseableReentrantLock ignored = in syncAllMediaFromCloudProvider()
341 try (CloseableReentrantLock ignored = mPickerSyncLockManager in syncAlbumMedia()
363 try (CloseableReentrantLock ignored = mPickerSyncLockManager in syncAlbumMediaFromCloudProvider()
380 try (CloseableReentrantLock ignored = mPickerSyncLockManager in resetAllMedia()
468 try (CloseableReentrantLock ignored = mPickerSyncLockManager in setCloudProviderInternal()
478 try (CloseableReentrantLock ignored = mPickerSyncLockManager in setCloudProviderInternal()
510 try (CloseableReentrantLock ignored = mPickerSyncLockManager in getCurrentCloudProviderInfo()
522 try (CloseableReentrantLock ignored = mPickerSyncLockManager in setCurrentCloudProviderInfo()
[all …]
/packages/providers/MediaProvider/src/com/android/providers/media/photopicker/data/
DPickerDbFacade.java54 import com.android.providers.media.photopicker.sync.CloseableReentrantLock;
226 try (CloseableReentrantLock ignored = mPickerSyncLockManager in setCloudProvider()
243 try (CloseableReentrantLock ignored = in setCloudProviderWithTimeout()
259 try (CloseableReentrantLock ignored = mPickerSyncLockManager in getCloudProvider()
1036 try (CloseableReentrantLock ignored = mPickerSyncLockManager in queryMediaIdForApps()
1164 try (CloseableReentrantLock ignored = mPickerSyncLockManager in queryMediaForUi()