Class IntentOperation


  • @Beta
    public final class IntentOperation
    extends java.lang.Object
    Abstraction of an intent-related operation, e.g. add, remove, replace.
    • Constructor Detail

      • IntentOperation

        public IntentOperation​(IntentOperation.Type type,
                               Intent intent)
        Creates an intent operation.
        Parameters:
        type - operation type
        intent - intent subject
    • Method Detail

      • type

        public IntentOperation.Type type()
        Returns the type of the operation.
        Returns:
        operation type
      • intentId

        public IntentId intentId()
        Returns the identifier of the intent to which this operation applies.
        Returns:
        intent identifier
      • key

        public Key key()
        Returns the key for this intent.
        Returns:
        key value
      • intent

        public Intent intent()
        Returns the intent to which this operation applied. For remove, this can be null.
        Returns:
        intent that is the subject of the operation; null for remove
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • equals

        public boolean equals​(java.lang.Object obj)
        Overrides:
        equals in class java.lang.Object
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object