com.hazelcast.jet.core

## Class BroadcastKey<K>

- java.lang.Object
- - com.hazelcast.jet.core.BroadcastKey<K>

- Type Parameters:
    `K` - type of key

      public final class BroadcastKey<K>
      extends Object

  Marks a key in the snapshot state to indicate that the corresponding entry should be broadcast to all processors when restoring the snapshot.
  Since:
    3.0

- - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static <K> BroadcastKey<K>` | `broadcastKey(K key)` Returns a given key as a broadcast key.
    `boolean` | `equals(Object o)`
    `int` | `hashCode()`
    `K` | `key()` Returns the underlying key
    `String` | `toString()`

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

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

- - ### Method Detail

    - #### key

          @Nonnull
          public K key()

      Returns the underlying key

    - #### broadcastKey

          @Nonnull
          public static <K> BroadcastKey<K> broadcastKey(@Nonnull
                                                                  K key)

      Returns a given key as a broadcast key.

      Note: Several processor instances can use the returned `BroadcastKey` with the same `key` to store unique values and the values will not overwrite each other. Upon a snapshot restore, each processor will receive multiple key-value pairs with the given BroadcastKey

    - #### equals

          public boolean equals(Object o)

      Overrides:
        `equals` in class `Object`

    - #### hashCode

          public int hashCode()

      Overrides:
        `hashCode` in class `Object`

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Object`

Copyright © 2020. All rights reserved.