Interface FlagAffectedCommand

All Superinterfaces:
ReplicableCommand, TracedCommand, VisitableCommand
All Known Subinterfaces:
DataCommand
All Known Implementing Classes:
org.infinispan.commands.read.AbstractDataCommand, AbstractFlagAffectedCommand, AbstractTopologyAffectedCommand, TouchCommand

public interface FlagAffectedCommand extends VisitableCommand
Flags modify behavior of command such as whether or not to invoke certain commands remotely, check cache store etc.
Since:
5.0
Author:
William Burns, Sanne Grinovero
  • Method Details

    • getFlags

      default Set<Flag> getFlags()
      Returns:
      The command flags - only valid to invoke after setFlagsBitSet(long). The set should not be modified directly, only via the setFlagsBitSet(long), addFlags(long) and addFlags(long) methods.
    • getFlagsBitSet

      long getFlagsBitSet()
      Returns:
      The command flags. Flags can be modified with setFlagsBitSet(long), addFlags(long) and addFlags(long) methods.
    • setFlagsBitSet

      void setFlagsBitSet(long bitSet)
      Set the flags, replacing any existing flags.
    • addFlags

      default void addFlags(long flagsBitSet)
      Add a set of flags to the command.
      Parameters:
      flagsBitSet - The flags to add, usually a FlagBitSets constant (or combination thereof).
    • hasAnyFlag

      default boolean hasAnyFlag(long flagsBitSet)
      Check whether any of the flags in the flagsBitSet parameter is present in the command. Should be used with the constants in FlagBitSets.
    • hasAllFlags

      default boolean hasAllFlags(long flagBitSet)
      Check whether all of the flags in the flagsBitSet parameter are present in the command. Should be used with the constants in FlagBitSets.