summaryrefslogtreecommitdiff
path: root/server/connection.h
diff options
context:
space:
mode:
Diffstat (limited to 'server/connection.h')
-rw-r--r--server/connection.h13
1 files changed, 11 insertions, 2 deletions
diff --git a/server/connection.h b/server/connection.h
index ff5ee98..22301b1 100644
--- a/server/connection.h
+++ b/server/connection.h
@@ -1,5 +1,5 @@
/*
- * $Id: connection.h,v 1.9 2010/07/19 13:49:31 schmirl Exp $
+ * $Id: connection.h,v 1.10 2010/08/03 10:46:41 schmirl Exp $
*/
#ifndef VDR_STREAMDEV_SERVER_CONNECTION_H
@@ -35,6 +35,11 @@ private:
tStrStrMap m_Headers;
+ /* Check if a device would be available for transfering the given
+ channel. This call has no side effects except for temporarily
+ detaching this connection's receivers. */
+ cDevice *CheckDevice(const cChannel *Channel, int Priority, bool LiveView, const cDevice *AvoidDevice = NULL);
+
protected:
/* Will be called when a command terminated by a newline has been
received */
@@ -91,10 +96,14 @@ public:
/* Will make the socket close after sending all queued output data */
void DeferClose(void) { m_DeferClose = true; }
- /* Will retrieve an unused device for transmitting data. Use the returned
+ /* Will retrieve an unused device for transmitting data. Receivers have
+ already been attached from the device if necessary. Use the returned
cDevice in a following call to StartTransfer */
cDevice *GetDevice(const cChannel *Channel, int Priority);
+ /* Test if a call to GetDevice would return a usable device. */
+ bool ProvidesChannel(const cChannel *Channel, int Priority);
+
virtual void Flushed(void) {}
virtual void Detach(void) = 0;