Package com.apollographql.apollo
Interface ApolloMutationCall.Factory
-
- All Known Implementing Classes:
ApolloClient
- Enclosing interface:
- ApolloMutationCall<T>
public static interface ApolloMutationCall.FactoryFactory for creatingApolloMutationCallcalls.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description <D extends com.apollographql.apollo.api.Operation.Data,T,V extends com.apollographql.apollo.api.Operation.Variables>
ApolloMutationCall<T>mutate(com.apollographql.apollo.api.Mutation<D,T,V> mutation)Creates and prepares a newApolloMutationCallcall.<D extends com.apollographql.apollo.api.Operation.Data,T,V extends com.apollographql.apollo.api.Operation.Variables>
ApolloMutationCall<T>mutate(com.apollographql.apollo.api.Mutation<D,T,V> mutation, D withOptimisticUpdates)Creates and prepares a newApolloMutationCallcall with optimistic updates.
-
-
-
Method Detail
-
mutate
<D extends com.apollographql.apollo.api.Operation.Data,T,V extends com.apollographql.apollo.api.Operation.Variables> ApolloMutationCall<T> mutate(@NotNull com.apollographql.apollo.api.Mutation<D,T,V> mutation)
Creates and prepares a newApolloMutationCallcall.- Parameters:
mutation- theMutationwhich needs to be performed- Returns:
- prepared
ApolloMutationCallcall to be executed at some point in the future
-
mutate
<D extends com.apollographql.apollo.api.Operation.Data,T,V extends com.apollographql.apollo.api.Operation.Variables> ApolloMutationCall<T> mutate(@NotNull com.apollographql.apollo.api.Mutation<D,T,V> mutation, @NotNull D withOptimisticUpdates)
Creates and prepares a new
Provided optimistic updates will be stored inApolloMutationCallcall with optimistic updates.ApolloStoreimmediately before mutation execution. AnyApolloQueryWatcherdependent on the changed cache records will be re-fetched.- Parameters:
mutation- theMutationwhich needs to be performedwithOptimisticUpdates- optimistic updates for this mutation- Returns:
- prepared
ApolloMutationCallcall to be executed at some point in the future
-
-