Skip to content

Instantly share code, notes, and snippets.

@pdeschen
Created April 7, 2010 01:02
Show Gist options
  • Save pdeschen/358342 to your computer and use it in GitHub Desktop.
Save pdeschen/358342 to your computer and use it in GitHub Desktop.
def sequencer =
{ sequence, closure ->
if (dtmfSequencerEnabled)
{
for (dtmf in sequence)
{
switch (dtmf)
{
case "*":say("${baseAudioUrl}/dtmf/star.wav");;
case "#":say("${baseAudioUrl}/dtmf/pound.wav");
default:
say("${baseAudioUrl}/dtmf/${dtmf.toLowerCase()}.wav");
}
}
}
if (closure) return closure()
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment