Package org.kie.api.executor

## Class CommandContext

- java.lang.Object
- - org.kie.api.executor.CommandContext

- All Implemented Interfaces:
    `Serializable`

      public class CommandContext
      extends Object
      implements Serializable

  Data holder for any contextual data that shall be given to the command upon execution. Important note that every object that is added to the data container must be serializable meaning it must implement `java.io.Seriazliable`
  See Also:
    Serialized Form

- - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `CommandContext()` |
    `CommandContext​(Map<String,​Object> data)` |

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `Map<String,​Object>` | `getData()` |
    `Object` | `getData​(String key)` |
    `Set<String>` | `keySet()` |
    `void` | `setData​(String key, Object value)` |
    `void` | `setData​(Map<String,​Object> data)` |
    `String` | `toString()` |

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

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

- - ### Constructor Detail

    - #### CommandContext

          public CommandContext()

    - #### CommandContext

          public CommandContext​(Map<String,​Object> data)

  - ### Method Detail

    - #### setData

          public void setData​(Map<String,​Object> data)

    - #### getData

          public Map<String,​Object> getData()

    - #### getData

          public Object getData​(String key)

    - #### setData

          public void setData​(String key,
                              Object value)

    - #### keySet

          public Set<String> keySet()

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Object`