org.teleal.cling.protocol.sync
Class ReceivingAction

java.lang.Object
  extended by org.teleal.cling.protocol.ReceivingAsync<IN>
      extended by org.teleal.cling.protocol.ReceivingSync<StreamRequestMessage,StreamResponseMessage>
          extended by org.teleal.cling.protocol.sync.ReceivingAction
All Implemented Interfaces:
Runnable

public class ReceivingAction
extends ReceivingSync<StreamRequestMessage,StreamResponseMessage>

Handles reception of control messages, invoking actions on local services.

Actions are invoked through the ActionExecutor returned by the registered LocalService.getExecutor(org.teleal.cling.model.meta.Action) method.

This class offers two shortcut thread-local variables, which providers of UPnP services might find useful in some situations. You can access these methods statically from within your service implementation:

Author:
Christian Bauer

Field Summary
protected static ThreadLocal<UpnpHeaders> extraResponseHeadersThreadLocal
           
protected static ThreadLocal<IncomingActionRequestMessage> requestThreadLocal
           
 
Fields inherited from class org.teleal.cling.protocol.ReceivingSync
outputMessage
 
Constructor Summary
ReceivingAction(UpnpService upnpService, StreamRequestMessage inputMessage)
           
 
Method Summary
protected  StreamResponseMessage executeSync()
           
static UpnpHeaders getExtraResponseHeaders()
           
static IncomingActionRequestMessage getRequestMessage()
           
 
Methods inherited from class org.teleal.cling.protocol.ReceivingSync
execute, getOutputMessage, responseException, responseSent, toString
 
Methods inherited from class org.teleal.cling.protocol.ReceivingAsync
getFirstHeader, getInputMessage, getUpnpService, run, waitBeforeExecution
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

requestThreadLocal

protected static final ThreadLocal<IncomingActionRequestMessage> requestThreadLocal

extraResponseHeadersThreadLocal

protected static final ThreadLocal<UpnpHeaders> extraResponseHeadersThreadLocal
Constructor Detail

ReceivingAction

public ReceivingAction(UpnpService upnpService,
                       StreamRequestMessage inputMessage)
Method Detail

executeSync

protected StreamResponseMessage executeSync()
Specified by:
executeSync in class ReceivingSync<StreamRequestMessage,StreamResponseMessage>

getRequestMessage

public static IncomingActionRequestMessage getRequestMessage()

getExtraResponseHeaders

public static UpnpHeaders getExtraResponseHeaders()


Copyright © 2011 Teleal GmbH, Switzerland. All Rights Reserved.