test_class.declarator: mStorage
test_class.modifier: private
test_class.original_string: private AsyncStorageModule mStorage;
test_class.type: AsyncStorageModule
test_class.var_name: mStorage
test_class.declarator: mEmptyArray
test_class.modifier: private
test_class.original_string: private JavaOnlyArray mEmptyArray;
test_class.type: JavaOnlyArray
test_class.var_name: mEmptyArray
test_class.declarator: rule = new PowerMockRule()
test_class.modifier: @Rule
    public
test_class.original_string: @Rule
    public PowerMockRule rule = new PowerMockRule();
test_class.type: PowerMockRule
test_class.var_name: rule
test_class.file: node_modules/react-native/ReactAndroid/src/test/java/com/facebook/react/modules/storage/AsyncStorageModuleTest.java
test_class.identifier: AsyncStorageModuleTest
test_case.body: @Test
    public void testMultiRemove() {
      final String key1 = "foo1";
      final String key2 = "foo2";
      final String value1 = "bar1";
      final String value2 = "bar2";
  
      JavaOnlyArray keyValues = new JavaOnlyArray();
      keyValues.pushArray(getArray(key1, value1));
      keyValues.pushArray(getArray(key2, value2));
      mStorage.multiSet(keyValues, mock(Callback.class));
  
      JavaOnlyArray keys = new JavaOnlyArray();
      keys.pushString(key1);
      keys.pushString(key2);
  
      Callback getCallback = mock(Callback.class);
      mStorage.multiRemove(keys, getCallback);
      Mockito.verify(getCallback, Mockito.times(1)).invoke();
  
      Callback getAllCallback = mock(Callback.class);
      mStorage.getAllKeys(getAllCallback);
      Mockito.verify(getAllCallback, Mockito.times(1)).invoke(null, mEmptyArray);
  
      mStorage.multiSet(keyValues, mock(Callback.class));
  
      keys.pushString("fakeKey");
      Callback getCallback2 = mock(Callback.class);
      mStorage.multiRemove(keys, getCallback2);
      Mockito.verify(getCallback2, Mockito.times(1)).invoke();
  
      Callback getAllCallback2 = mock(Callback.class);
      mStorage.getAllKeys(getAllCallback2);
      Mockito.verify(getAllCallback2, Mockito.times(1)).invoke(null, mEmptyArray);
    }
test_case.class_method_signature: AsyncStorageModuleTest.testMultiRemove()
test_case.full_signature: @Test public void testMultiRemove()
test_case.identifier: testMultiRemove
test_case.invocations: pushArray getArray pushArray getArray multiSet mock pushString pushString mock multiRemove invoke verify times mock getAllKeys invoke verify times multiSet mock pushString mock multiRemove invoke verify times mock getAllKeys invoke verify times
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testMultiRemove()
focal_class.declarator: MAX_SQL_KEYS = 999
focal_class.modifier: private static final
focal_class.original_string: private static final int MAX_SQL_KEYS = 999;
focal_class.type: int
focal_class.var_name: MAX_SQL_KEYS
focal_class.declarator: mReactDatabaseSupplier
focal_class.modifier: private
focal_class.original_string: private ReactDatabaseSupplier mReactDatabaseSupplier;
focal_class.type: ReactDatabaseSupplier
focal_class.var_name: mReactDatabaseSupplier
focal_class.declarator: mShuttingDown = false
focal_class.modifier: private
focal_class.original_string: private boolean mShuttingDown = false;
focal_class.type: boolean
focal_class.var_name: mShuttingDown
focal_class.file: node_modules/react-native/ReactAndroid/src/main/java/com/facebook/react/modules/storage/AsyncStorageModule.java
focal_class.identifier: AsyncStorageModule
focal_class.interfaces: implements ModuleDataCleaner.Cleanable
focal_class.class_method_signature: AsyncStorageModule.AsyncStorageModule(ReactApplicationContext reactContext)
focal_class.full_signature: public  AsyncStorageModule(ReactApplicationContext reactContext)
focal_class.identifier: AsyncStorageModule
focal_class.modifiers: public
focal_class.parameters: (ReactApplicationContext reactContext)
focal_class.signature:  AsyncStorageModule(ReactApplicationContext reactContext)
focal_class.class_method_signature: AsyncStorageModule.getName()
focal_class.full_signature: @Override public String getName()
focal_class.identifier: getName
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: String
focal_class.signature: String getName()
focal_class.class_method_signature: AsyncStorageModule.initialize()
focal_class.full_signature: @Override public void initialize()
focal_class.identifier: initialize
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void initialize()
focal_class.class_method_signature: AsyncStorageModule.onCatalystInstanceDestroy()
focal_class.full_signature: @Override public void onCatalystInstanceDestroy()
focal_class.identifier: onCatalystInstanceDestroy
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void onCatalystInstanceDestroy()
focal_class.class_method_signature: AsyncStorageModule.clearSensitiveData()
focal_class.full_signature: @Override public void clearSensitiveData()
focal_class.identifier: clearSensitiveData
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void clearSensitiveData()
focal_class.class_method_signature: AsyncStorageModule.multiGet(final ReadableArray keys, final Callback callback)
focal_class.full_signature: @ReactMethod public void multiGet(final ReadableArray keys, final Callback callback)
focal_class.identifier: multiGet
focal_class.modifiers: @ReactMethod public
focal_class.parameters: (final ReadableArray keys, final Callback callback)
focal_class.return: void
focal_class.signature: void multiGet(final ReadableArray keys, final Callback callback)
focal_class.class_method_signature: AsyncStorageModule.multiSet(final ReadableArray keyValueArray, final Callback callback)
focal_class.full_signature: @ReactMethod public void multiSet(final ReadableArray keyValueArray, final Callback callback)
focal_class.identifier: multiSet
focal_class.modifiers: @ReactMethod public
focal_class.parameters: (final ReadableArray keyValueArray, final Callback callback)
focal_class.return: void
focal_class.signature: void multiSet(final ReadableArray keyValueArray, final Callback callback)
focal_class.class_method_signature: AsyncStorageModule.multiRemove(final ReadableArray keys, final Callback callback)
focal_class.full_signature: @ReactMethod public void multiRemove(final ReadableArray keys, final Callback callback)
focal_class.identifier: multiRemove
focal_class.modifiers: @ReactMethod public
focal_class.parameters: (final ReadableArray keys, final Callback callback)
focal_class.return: void
focal_class.signature: void multiRemove(final ReadableArray keys, final Callback callback)
focal_class.class_method_signature: AsyncStorageModule.multiMerge(final ReadableArray keyValueArray, final Callback callback)
focal_class.full_signature: @ReactMethod public void multiMerge(final ReadableArray keyValueArray, final Callback callback)
focal_class.identifier: multiMerge
focal_class.modifiers: @ReactMethod public
focal_class.parameters: (final ReadableArray keyValueArray, final Callback callback)
focal_class.return: void
focal_class.signature: void multiMerge(final ReadableArray keyValueArray, final Callback callback)
focal_class.class_method_signature: AsyncStorageModule.clear(final Callback callback)
focal_class.full_signature: @ReactMethod public void clear(final Callback callback)
focal_class.identifier: clear
focal_class.modifiers: @ReactMethod public
focal_class.parameters: (final Callback callback)
focal_class.return: void
focal_class.signature: void clear(final Callback callback)
focal_class.class_method_signature: AsyncStorageModule.getAllKeys(final Callback callback)
focal_class.full_signature: @ReactMethod public void getAllKeys(final Callback callback)
focal_class.identifier: getAllKeys
focal_class.modifiers: @ReactMethod public
focal_class.parameters: (final Callback callback)
focal_class.return: void
focal_class.signature: void getAllKeys(final Callback callback)
focal_class.class_method_signature: AsyncStorageModule.ensureDatabase()
focal_class.full_signature: private boolean ensureDatabase()
focal_class.identifier: ensureDatabase
focal_class.modifiers: private
focal_class.parameters: ()
focal_class.return: boolean
focal_class.signature: boolean ensureDatabase()
focal_class.superclass: extends ReactContextBaseJavaModule
focal_method.body: @ReactMethod
    public void multiRemove(final ReadableArray keys, final Callback callback) {
      if (keys.size() == 0) {
        callback.invoke(AsyncStorageErrorUtil.getInvalidKeyError(null));
        return;
      }
  
      new GuardedAsyncTask<Void, Void>(getReactApplicationContext()) {
        @Override
        protected void doInBackgroundGuarded(Void... params) {
          if (!ensureDatabase()) {
            callback.invoke(AsyncStorageErrorUtil.getDBError(null));
            return;
          }
  
          WritableMap error = null;
          try {
            mReactDatabaseSupplier.get().beginTransaction();
            for (int keyStart = 0; keyStart < keys.size(); keyStart += MAX_SQL_KEYS) {
              int keyCount = Math.min(keys.size() - keyStart, MAX_SQL_KEYS);
              mReactDatabaseSupplier.get().delete(
                  TABLE_CATALYST,
                  AsyncLocalStorageUtil.buildKeySelection(keyCount),
                  AsyncLocalStorageUtil.buildKeySelectionArgs(keys, keyStart, keyCount));
            }
            mReactDatabaseSupplier.get().setTransactionSuccessful();
          } catch (Exception e) {
            FLog.w(ReactConstants.TAG, e.getMessage(), e);
            error = AsyncStorageErrorUtil.getError(null, e.getMessage());
          } finally {
            try {
            mReactDatabaseSupplier.get().endTransaction();
            } catch (Exception e) {
              FLog.w(ReactConstants.TAG, e.getMessage(), e);
              if (error == null) {
                error = AsyncStorageErrorUtil.getError(null, e.getMessage());
              }
            }
          }
          if (error != null) {
            callback.invoke(error);
          } else {
            callback.invoke();
          }
        }
      }.execute();
    }
focal_method.class_method_signature: AsyncStorageModule.multiRemove(final ReadableArray keys, final Callback callback)
focal_method.full_signature: @ReactMethod public void multiRemove(final ReadableArray keys, final Callback callback)
focal_method.identifier: multiRemove
focal_method.invocations: size invoke getInvalidKeyError execute getReactApplicationContext ensureDatabase invoke getDBError beginTransaction get size min size delete get buildKeySelection buildKeySelectionArgs setTransactionSuccessful get w getMessage getError getMessage endTransaction get w getMessage getError getMessage invoke invoke
focal_method.modifiers: @ReactMethod public
focal_method.parameters: (final ReadableArray keys, final Callback callback)
focal_method.return: void
focal_method.signature: void multiRemove(final ReadableArray keys, final Callback callback)