/** * <p>Adds provided {@link AppSyncMutationCall} that is currently in progress.</p> * * <p><b>Note</b>: This method needs to be called right before an apolloCall is executed.</p> */ void registerMutationCall(@Nonnull AppSyncMutationCall appSyncMutationCall) { checkNotNull(appSyncMutationCall, "appSyncMutationCall == null"); OperationName operationName = appSyncMutationCall.operation().name(); registerCall(activeMutationCalls, operationName, appSyncMutationCall); }
/** * <p>Adds provided {@link AppSyncMutationCall} that is currently in progress.</p> * * <p><b>Note</b>: This method needs to be called right before an apolloCall is executed.</p> */ void registerMutationCall(@Nonnull AppSyncMutationCall appSyncMutationCall) { checkNotNull(appSyncMutationCall, "appSyncMutationCall == null"); OperationName operationName = appSyncMutationCall.operation().name(); registerCall(activeMutationCalls, operationName, appSyncMutationCall); }
/** * <p>Removes provided {@link AppSyncMutationCall} that finished his execution, if it is found, else throws an * {@link AssertionError}.</p> * * If the removal operation is successful and no active running calls are found, then the registered * {@link ApolloCallTracker#idleResourceCallback} is invoked. * * <p><b>Note</b>: This method needs to be called right after an apolloCall is completed (whether successful or * failed).</p> */ void unregisterMutationCall(@Nonnull AppSyncMutationCall appSyncMutationCall) { checkNotNull(appSyncMutationCall, "appSyncMutationCall == null"); OperationName operationName = appSyncMutationCall.operation().name(); unregisterCall(activeMutationCalls, operationName, appSyncMutationCall); }
/** * <p>Removes provided {@link AppSyncMutationCall} that finished his execution, if it is found, else throws an * {@link AssertionError}.</p> * * If the removal operation is successful and no active running calls are found, then the registered * {@link ApolloCallTracker#idleResourceCallback} is invoked. * * <p><b>Note</b>: This method needs to be called right after an apolloCall is completed (whether successful or * failed).</p> */ void unregisterMutationCall(@Nonnull AppSyncMutationCall appSyncMutationCall) { checkNotNull(appSyncMutationCall, "appSyncMutationCall == null"); OperationName operationName = appSyncMutationCall.operation().name(); unregisterCall(activeMutationCalls, operationName, appSyncMutationCall); }