org.fourthline.cling.protocol.sync

## Class SendingEvent

- java.lang.Object
- - org.fourthline.cling.protocol.SendingAsync
  - - org.fourthline.cling.protocol.SendingSync<OutgoingEventRequestMessage,StreamResponseMessage>
    - - org.fourthline.cling.protocol.sync.SendingEvent

- All Implemented Interfaces:
    Runnable

      public class SendingEvent
      extends SendingSync<OutgoingEventRequestMessage,StreamResponseMessage>

  Sending GENA event messages to remote subscribers.

  Any `LocalGENASubscription` instantiates and executes this protocol when the state of a local service changes. However, a remote subscriber might require event notification messages on more than one callback URL, so this protocol potentially sends many messages. What is returned is always the last response, that is, the response for the message sent to the last callback URL in the list of the subscriber.

  Author:
    Christian Bauer

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected UnsignedIntegerFourBytes` | `currentSequence`
    `protected OutgoingEventRequestMessage[]` | `requestMessages`
    `protected String` | `subscriptionId`

    - ### Fields inherited from class org.fourthline.cling.protocol.SendingSync

      `outputMessage`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `SendingEvent(UpnpService upnpService, LocalGENASubscription subscription)`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected StreamResponseMessage` | `executeSync()`

    - ### Methods inherited from class org.fourthline.cling.protocol.SendingSync

      `execute, getInputMessage, getOutputMessage, toString`

    - ### Methods inherited from class org.fourthline.cling.protocol.SendingAsync

      `getUpnpService, run`

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

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

- - ### Field Detail

    - #### subscriptionId

          protected final String subscriptionId

    - #### requestMessages

          protected final OutgoingEventRequestMessage[] requestMessages

    - #### currentSequence

          protected final UnsignedIntegerFourBytes currentSequence

  - ### Constructor Detail

    - #### SendingEvent

          public SendingEvent(UpnpService upnpService,
                      LocalGENASubscription subscription)

  - ### Method Detail

    - #### executeSync

          protected StreamResponseMessage executeSync()
                                               throws RouterException

      Specified by:
        `executeSync` in class `SendingSync<OutgoingEventRequestMessage,StreamResponseMessage>`
      Throws:
        `RouterException`

Copyright © 2014 4th Line GmbH, Switzerland. All Rights Reserved.