final boolean remove( Object key, Object value, EnumSet<Flag> explicitFlags, ClassLoader explicitClassLoader) { assertKeyNotNull(key); InvocationContext ctx = getInvocationContextWithImplicitTransaction(explicitFlags, explicitClassLoader); RemoveCommand command = commandsFactory.buildRemoveCommand(key, value, ctx.getFlags()); return (Boolean) executeCommandAndCommitIfNeeded(ctx, command); }
@SuppressWarnings("unchecked") final V remove(Object key, EnumSet<Flag> explicitFlags, ClassLoader explicitClassLoader) { assertKeyNotNull(key); InvocationContext ctx = getInvocationContextWithImplicitTransaction(explicitFlags, explicitClassLoader); RemoveCommand command = commandsFactory.buildRemoveCommand(key, null, ctx.getFlags()); return (V) executeCommandAndCommitIfNeeded(ctx, command); }
final NotifyingFuture<Boolean> removeAsync( Object key, Object value, EnumSet<Flag> explicitFlags, ClassLoader explicitClassLoader) { assertKeyNotNull(key); InvocationContext ctx = getInvocationContextWithImplicitTransaction(explicitFlags, explicitClassLoader); ctx.setUseFutureReturnType(true); RemoveCommand command = commandsFactory.buildRemoveCommand(key, value, ctx.getFlags()); return wrapInFuture(executeCommandAndCommitIfNeeded(ctx, command)); }
@Override public RemoveCommand buildRemoveCommand(Object key, Object value, Set<Flag> flags) { return actual.buildRemoveCommand(key, value, flags); }