Class Shout
In: shout.c
Parent: Object
Methods
agent    agent=    close    connect    delay    description    description=    disconnect    dumpfile    dumpfile=    format    format=    genre    genre=    host    host=    initialize    mount    mount=    name    name=    new    open    pass    pass=    password    password=    port    port=    protocol    protocol=    public    public=    send    sync    url    url=    user    user=    user_agent    user_agent=    username    username=    version   
Public Class methods
new(int argc, VALUE *argv, VALUE klass)

Make a new shout object. This method does not connect to any server. See connect.

version(VALUE klass)

Returns the libshout version, as a string.

Public Instance methods
initialize(...)
connect(VALUE self)

Connect to the server. You must set all the parameters you’re going to set before connecting.

open(VALUE self)

Connect to the server. You must set all the parameters you’re going to set before connecting.

disconnect(VALUE self)

Disconnect from the server.

close(VALUE self)

Disconnect from the server.

send(VALUE self, VALUE to_send)

Send some data. to_send is a String containing the data to send.

sync(VALUE self)

Sleep the necessary amount of time to play back the audio data sent since the last call to sync. After calling this, it’s time to send more data.

delay(VALUE self)

Return the proper amount of time, in milliseconds, before more data needs to be sent. This is for use when you would like to do something else in the intervening time period besides sleep.

host(VALUE self)

————————— getters —————————— :nodoc:

port()
user()
username()
pass()
password()
protocol()
format()
mount()
dumpfile()
agent()
user_agent()
public()
name()
url()
genre()
description()
host=(VALUE self, VALUE value)

Set the hostname to connect to. The default is localhost.

port=(VALUE self, VALUE value)

Set the destination port. The default is 8000.

user=(VALUE self, VALUE value)

Set the user to authenticate as. The default is "source".

username=(VALUE self, VALUE value)

Set the user to authenticate as. The default is "source".

pass=(VALUE self, VALUE value)

Set the password to authenticate with. The default is no password.

password=(VALUE self, VALUE value)

Set the password to authenticate with. The default is no password.

protocol=(VALUE self, VALUE value)

Set the protocol to use when connecting. Default is Shout::HTTP. Possible values are:

Shout::HTTP
HTTP; the protocol used by Icecast.
Shout::XAUDIOCAST
XAudioCast. Obsolete.
Shout::ICY
Icy. Obsolete. Used by Shoutcast.
format=(VALUE self, VALUE value)

Set the format of the audio. Possible values are:

Shout::VORBIS
Ogg Vorbis
Shout::MP3
MP3
mount=(VALUE self, VALUE value)

Set the mountpoint on the server.

dumpfile=(VALUE self, VALUE value)

Set a filename where the server should dump the data from this stream. Only do this if you know what you are doing.

agent=(VALUE self, VALUE value)

Set the User-Agent reported. The default is "libshout/<libshout version>", e.g. "libshout/2.0.0".

user_agent=(VALUE self, VALUE value)

Set the User-Agent reported. The default is "libshout/<libshout version>", e.g. "libshout/2.0.0".

public=(VALUE self, VALUE value)

Set whether or not this stream should be "public", i.e. advertised to a yp server such as yp.icecast.org. True or false. Nil counts as false.

name=(VALUE self, VALUE value)

Set the name of the stream, e.g. "monkey’s radio tunes."

url=(p1)
genre=(p1)
description=(p1)