Interface UpnpIOService


public interface UpnpIOService
The UpnpIOService is an interface that described the UPNP IO Service.
Author:
Karel Goderis - Initial contribution, Kai Kreuzer - added descriptor url retrieval
  • Method Details

    • invokeAction

      Map<String,String> invokeAction(UpnpIOParticipant participant, String serviceID, String actionID, Map<String,String> inputs)
      Invoke an UPNP Action
      Parameters:
      participant - the participant to invoke the action for
      serviceID - the UPNP service to invoke the action upon
      actionID - the Action to invoke
      inputs - a map of {variable,values} to parameterize the Action that will be invoked
    • addSubscription

      void addSubscription(UpnpIOParticipant participant, String serviceID, int duration)
      Subscribe to a GENA subscription
      Parameters:
      participant - the participant to the subscription is for
      serviceID - the UPNP service we want to subscribe to
      duration - the duration of the subscription
    • removeSubscription

      void removeSubscription(UpnpIOParticipant participant, String serviceID)
      Unsubscribe from a GENA subscription
      Parameters:
      participant - the participant of the subscription
      serviceID - the UPNP service we want to unsubscribe from
    • isRegistered

      boolean isRegistered(UpnpIOParticipant participant)
      Verify if the a participant is registered
      Parameters:
      participant - the participant whom's participation we want to verify
      Returns:
      true of the participant is registered with the UpnpIOService
    • registerParticipant

      void registerParticipant(UpnpIOParticipant participant)
      Register a participant with the UPNP IO Service
      Parameters:
      participant - the participant whose participation we want to register
    • unregisterParticipant

      void unregisterParticipant(UpnpIOParticipant participant)
      Unregister a participant with the UPNP IO Service
      Parameters:
      participant - the participant whose participation we want to unregister
    • getDescriptorURL

      URL getDescriptorURL(UpnpIOParticipant participant)
      Retrieves the descriptor url for the participant
      Parameters:
      participant - the participant whom's descriptor url is requested
      Returns:
      the url of the descriptor as provided by the upnp device
    • addStatusListener

      void addStatusListener(UpnpIOParticipant participant, String serviceID, String actionID, int interval)
      Establish a polling mechanism to check the status of a specific UDN device. The polling mechanism works by invoking the actionID on serviceID every interval. It is assumed that the actionID does not take/have to take any {variable,value} input set
      Parameters:
      participant - the participant for whom we want to set up a polling
      serviceID - the service to use for polling
      actionID - the action to call
      interval - the interval in seconds
    • removeStatusListener

      void removeStatusListener(UpnpIOParticipant participant)
      Stops the polling mechanism to check the status of a specific UDN device.
      Parameters:
      participant - the participant for whom we want to remove the polling