org.apache.geode.cache.operations

## Class InterestOperationContext

- java.lang.Object
- - org.apache.geode.cache.operations.OperationContext
  - - org.apache.geode.cache.operations.InterestOperationContext

- Direct Known Subclasses:
    RegisterInterestOperationContext, UnregisterInterestOperationContext

  Deprecated.
  since Geode1.0, use `ResourcePermission` instead

      public abstract class InterestOperationContext
      extends OperationContext

  Encapsulates registration/unregistration of interest in a region.
  Since:
    GemFire 5.5

- - ### Nested Class Summary

    - ### Nested classes/interfaces inherited from class org.apache.geode.cache.operations.OperationContext

      `OperationContext.OperationCode`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `InterestOperationContext(java.lang.Object key, InterestType interestType)` Deprecated. Constructor for the register interest operation.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods Deprecated Methods
    Modifier and Type | Method and Description
    --- | ---
    `InterestType` | `getInterestType()` Deprecated. Get the `InterestType` of this register/unregister operation.
    `java.lang.Object` | `getKey()` Deprecated. Get the key for this register/unregister interest operation.
    `boolean` | `isPostOperation()` Deprecated. True if the context is for post-operation.
    `void` | `setKey(java.lang.Object key)` Deprecated. Set the key for this register/unregister interest operation.

    - ### Methods inherited from class org.apache.geode.cache.operations.OperationContext

      `getOperationCode, isClientUpdate, isClientUpdate`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### InterestOperationContext

          public InterestOperationContext(java.lang.Object key,
                                          InterestType interestType)

      Deprecated.
      Constructor for the register interest operation.
      Parameters:
        `key` - the key or list of keys being registered/unregistered
        `interestType` - the `InterestType` of the register request

  - ### Method Detail

    - #### isPostOperation

          public boolean isPostOperation()

      Deprecated.
      True if the context is for post-operation.
      Specified by:
        `isPostOperation` in class `OperationContext`

    - #### getKey

          public java.lang.Object getKey()

      Deprecated.
      Get the key for this register/unregister interest operation.
      Returns:
        the key to be registered/unregistered.

    - #### setKey

          public void setKey(java.lang.Object key)

      Deprecated.
      Set the key for this register/unregister interest operation.
      Parameters:
        `key` - the new key

    - #### getInterestType

          public InterestType getInterestType()

      Deprecated.
      Get the `InterestType` of this register/unregister operation.
      Returns:
        the `InterestType` of this request.