Trees | Indices | Help |
---|
|
1 # -*- Mode: Python -*- 2 # vi:si:et:sw=4:sts=4:ts=4 3 # 4 # flumotion/component/consumers/shout2/shout2.py: stream to icecast2 5 # 6 # Flumotion - a streaming media server 7 # Copyright (C) 2005,2007 Fluendo, S.L. (www.fluendo.com). All rights reserved. 8 9 # This file may be distributed and/or modified under the terms of 10 # the GNU General Public License version 2 as published by 11 # the Free Software Foundation. 12 # This file is distributed without any warranty; without even the implied 13 # warranty of merchantability or fitness for a particular purpose. 14 # See "LICENSE.GPL" in the source distribution for more information. 15 16 # Licensees having purchased or holding a valid Flumotion Advanced 17 # Streaming Server license may use this file in accordance with the 18 # Flumotion Advanced Streaming Server Commercial License Agreement. 19 # See "LICENSE.Flumotion" in the source distribution for more information. 20 21 # Headers in this file shall remain intact. 22 23 from flumotion.component import feedcomponent 24 25 __version__ = "$Rev: 7162 $" 26 27295531 pipestr = 'shout2send name=shout2-streamer sync=1 protocol=3' 32 33 elprops = (('mount-point', 'mount'), 34 ('port', 'port'), 35 ('ip', 'ip'), 36 ('password', 'password'), 37 ('description', 'description'), 38 ('url', 'url'), 39 ('short-name', 'streamname')) 40 for k, v in elprops: 41 if k in properties: 42 # mind the gap, quote the values 43 pipestr += ' %s="%s"' % (v, properties[k]) 44 45 return pipestr4648 49 def _connection_problem(self, error): 50 # apparently error is an int 51 self.warning('Connection problem: %r', error)52 53 element = pipeline.get_by_name('shout2-streamer') 54 element.connect('connection-problem', _connection_problem)
Trees | Indices | Help |
---|
Generated by Epydoc 3.0.1 on Sun Nov 15 10:11:54 2009 | http://epydoc.sourceforge.net |