# Class: ProtectionEvents

## ProtectionEvents

#### new ProtectionEvents()

  Public facing external events to be used when including protection package.
  All public events will be aggregated into the MediaPlayerEvents Class and can be accessed
  via MediaPlayer.events. public_ is the prefix that we use to move event names to MediaPlayerEvents.

  Source:
    - streaming/protection/ProtectionEvents.js, line 36

### Events

#### KEY_ADDED

  Event ID for events delivered when a new key has been added

  Deprecated:
    - The latest versions of the EME specification no longer use this event. {@MediaPlayer.models.protectionModel.eventList.KEY_STATUSES_CHANGED} is preferred.
  Source:
    - streaming/protection/ProtectionEvents.js, line 59

#### KEY_ERROR

  Event ID for events delivered when an error is encountered by the CDM
  while processing a license server response message

  Source:
    - streaming/protection/ProtectionEvents.js, line 69

#### KEY_MESSAGE

  Event ID for events delivered when the protection set receives
  a key message from the CDM

  Source:
    - streaming/protection/ProtectionEvents.js, line 76

#### KEY_SESSION_CLOSED

  Event ID for events delivered when a key session close
  process has completed

  Source:
    - streaming/protection/ProtectionEvents.js, line 83

#### KEY_SESSION_CREATED

  Event ID for events delivered when a new key sessions creation
  process has completed

  Source:
    - streaming/protection/ProtectionEvents.js, line 90

#### KEY_SESSION_REMOVED

  Event ID for events delivered when a key session removal
  process has completed

  Source:
    - streaming/protection/ProtectionEvents.js, line 97

#### KEY_STATUSES_CHANGED

  Event ID for events delivered when the status of one or more
  decryption keys has changed

  Source:
    - streaming/protection/ProtectionEvents.js, line 104

#### KEY_SYSTEM_ACCESS_COMPLETE

  Event ID for events delivered when a key system access procedure
  has completed

  Source:
    - streaming/protection/ProtectionEvents.js, line 111

#### KEY_SYSTEM_SELECTED

  Event ID for events delivered when a key system selection procedure
  completes

  Source:
    - streaming/protection/ProtectionEvents.js, line 118

#### LICENSE_REQUEST_COMPLETE

  Event ID for events delivered when a license request procedure
  has completed

  Source:
    - streaming/protection/ProtectionEvents.js, line 125

#### LICENSE_REQUEST_SENDING

  Sending a license rquest

  Source:
    - streaming/protection/ProtectionEvents.js, line 132

#### PROTECTION_CREATED

  Event ID for events delivered when the Protection system is detected and created.

  Source:
    - streaming/protection/ProtectionEvents.js, line 144

#### PROTECTION_DESTROYED

  Event ID for events delivered when the Protection system is destroyed.

  Source:
    - streaming/protection/ProtectionEvents.js, line 150

#### Search results