twiml-0.2.0.0: TwiML library for Haskell

Copyright(C) 2014-15 Mark Andrus Roberts
LicenseBSD-style (see the file LICENSE)
MaintainerMark Andrus Roberts <markandrusroberts@gmail.com>
Stabilityprovisional
Safe HaskellNone
LanguageHaskell98

Text.XML.Twiml.Internal.Twiml

Contents

Description

This module defines all of the TwiML verbs and nouns in a single place (mainly due to a few mutually-recursive definitions). This modules also exposeses the internals of each TwiML's attributes.

Prefer the definitions re-exported by the Text.XML.Twiml and Text.XML.Twiml.Verbs modules to those exported here.

Synopsis

TwiML

data VoiceTwiml

Constructors

forall i . VoiceTwiml (IxFree VoiceVerbsF i Void) 

newtype VoiceVerbsF i a

Constructors

VoiceVerbsF 

Fields

getVoiceVerbsF :: (SayF i :+: (PlayF i :+: (GatherF i :+: (SmsF i :+: (DialF i :+: (EnqueueF i :+: (LeaveF i :+: (HangupF i :+: (RecordF i :+: (RedirectF i :+: (RejectF i :+: (PauseF i :+: EndF i)))))))))))) a
 

Instances

Functor (VoiceVerbsF i) 
Show1 [*] VoiceVerbsF 
Functor1 [*] VoiceVerbsF 
(:<:) (f i) ((:+:) * (SayF i) ((:+:) * (PlayF i) ((:+:) * (GatherF i) ((:+:) * (SmsF i) ((:+:) * (DialF i) ((:+:) * (EnqueueF i) ((:+:) * (LeaveF i) ((:+:) * (HangupF i) ((:+:) * (RecordF i) ((:+:) * (RedirectF i) ((:+:) * (RejectF i) ((:+:) * (PauseF i) (EndF i))))))))))))) => (f i) :<: (VoiceVerbsF i) 
Show a => Show (VoiceVerbsF i a) 
Generic (VoiceVerbsF i a) 
ToXML a => ToXML (VoiceVerbsF i a) 
ToXML (IxFree * VoiceVerbsF i Void) 
type Rep (VoiceVerbsF i a) 

type family Base d

Base maps the empty data declaration for a TwiML verb to its corresponding base functor.

type IsTwimlLike f i = (Functor1 f, Base i `[i]` :<: f `[i]`)

type TwimlLike f i = TwimlLike' f `[i]`

type TwimlLike' f = IxFree f

Nouns

data DialNoun

Constructors

forall i . DialNoun (IxFree DialNounF i Void) 

newtype DialNounF i a

Constructors

DialNounF 

Fields

getDialNounF :: (ClientF i :+: (ConferenceF i :+: (NumberF i :+: (QueueF i :+: SipF i)))) a
 

Instances

Functor (DialNounF i) 
Show1 [*] DialNounF 
Functor1 [*] DialNounF 
(:<:) (f i) ((:+:) * (ClientF i) ((:+:) * (ConferenceF i) ((:+:) * (NumberF i) ((:+:) * (QueueF i) (SipF i))))) => (f i) :<: (DialNounF i) 
Show a => Show (DialNounF i a) 
Generic (DialNounF i a) 
ToXML a => ToXML (DialNounF i a) 
ToXML (IxFree * DialNounF i Void) 
type Rep (DialNounF i a) 

Client

data Client

data ClientF i a

Constructors

(Proxy i ~ Proxy `[Client]`) => ClientF String ClientAttributes 

Instances

Functor (ClientF i) 
Functor1 [*] ClientF 
Show a => Show (ClientF i a) 
ToXML (ClientF i a) 

Conference

Number

data Number

data NumberF i a

Constructors

(Proxy i ~ Proxy `[Number]`) => NumberF String NumberAttributes 

Instances

Functor (NumberF i) 
Functor1 [*] NumberF 
Show a => Show (NumberF i a) 
ToXML (NumberF i a) 

Queue

data Queue

data QueueF i a

Constructors

(Proxy i ~ Proxy `[Queue]`) => QueueF String QueueAttributes 

Instances

Functor (QueueF i) 
Functor1 [*] QueueF 
Show a => Show (QueueF i a) 
ToXML (QueueF i a) 

Sip

data Sip

data SipF i a

Constructors

(Proxy i ~ Proxy `[Sip]`) => SipF URL SipAttributes 

Instances

Functor (SipF i) 
Functor1 [*] SipF 
Show a => Show (SipF i a) 
ToXML (SipF i a) 

Verbs

Dial

data Dial

data DialF i a

Constructors

(Proxy i ~ Proxy `[Dial]`) => DialF EitherDialNounString DialAttributes a 

Instances

Functor (DialF i) 
Functor1 [*] DialF 
Show a => Show (DialF i a) 
ToXML a => ToXML (DialF i a) 

End

data End

data EndF i a

Constructors

(Proxy i ~ Proxy `[End]`) => EndF 

Instances

Functor (EndF i) 
Functor1 [*] EndF 
Show a => Show (EndF i a) 
ToXML (EndF i a) 

Enqueue

data Enqueue

data EnqueueF i a

Constructors

(Proxy i ~ Proxy `[Enqueue]`) => EnqueueF String EnqueueAttributes a 

Instances

Functor (EnqueueF i) 
Functor1 [*] EnqueueF 
Show a => Show (EnqueueF i a) 
ToXML a => ToXML (EnqueueF i a) 

Hangup

data Gather

data GatherF i a where

Constructors

GatherF :: Nest i In Gather => GatherAttributes -> IxFree VoiceVerbsF i Void -> a -> GatherF `[Gather]` a 

Instances

Functor (GatherF i) 
Functor1 [*] GatherF 
Show a => Show (GatherF i a) 
ToXML a => ToXML (GatherF i a) 

type family Nest a i b

Equations

Nest i In Gather = (Record i, Gather i, Sms i, Dial i, Enqueue i, Leave i, Hangup i, Redirect i, Reject i) 

data In

Hangup

data Hangup

data HangupF i a

Constructors

(Proxy i ~ Proxy `[Hangup]`) => HangupF 

Instances

Functor (HangupF i) 
Functor1 [*] HangupF 
Show a => Show (HangupF i a) 
ToXML (HangupF i a) 

Leave

data Leave

data LeaveF i a

Constructors

(Proxy i ~ Proxy `[Leave]`) => LeaveF 

Instances

Functor (LeaveF i) 
Functor1 [*] LeaveF 
Show a => Show (LeaveF i a) 
ToXML (LeaveF i a) 

Message

data Message

data MessageF i a

Constructors

(Proxy i ~ Proxy `[Message]`) => MessageF String MessageAttributes a 

Instances

Functor (MessageF i) 
Functor1 [*] MessageF 
Show a => Show (MessageF i a) 
ToXML a => ToXML (MessageF i a) 

Pause

data Pause

data PauseF i a

Constructors

(Proxy i ~ Proxy `[Pause]`) => PauseF PauseAttributes a 

Instances

Functor (PauseF i) 
Functor1 [*] PauseF 
Show a => Show (PauseF i a) 
ToXML a => ToXML (PauseF i a) 

Play

data Play

data PlayF i a

Constructors

(Proxy i ~ Proxy `[Play]`) => PlayF MaybeURL PlayAttributes a 

Instances

Functor (PlayF i) 
Functor1 [*] PlayF 
Show a => Show (PlayF i a) 
ToXML a => ToXML (PlayF i a) 

Record

data Record

data RecordF i a

Constructors

(Proxy i ~ Proxy `[Record]`) => RecordF RecordAttributes a 

Instances

Functor (RecordF i) 
Functor1 [*] RecordF 
Show a => Show (RecordF i a) 
ToXML a => ToXML (RecordF i a) 

Redirect

data RedirectF i a

Constructors

(Proxy i ~ Proxy `[Redirect]`) => RedirectF URL RedirectAttributes 

Instances

Reject

data Reject

data RejectF i a

Constructors

(Proxy i ~ Proxy `[Reject]`) => RejectF RejectAttributes 

Instances

Functor (RejectF i) 
Functor1 [*] RejectF 
Show a => Show (RejectF i a) 
ToXML (RejectF i a) 

Say

data Say

data SayF i a

Constructors

(Proxy i ~ Proxy `[Say]`) => SayF String SayAttributes a 

Instances

Functor (SayF i) 
Functor1 [*] SayF 
Show a => Show (SayF i a) 
ToXML a => ToXML (SayF i a) 

Sms

data Sms

data SmsF i a

Constructors

(Proxy i ~ Proxy `[Sms]`) => SmsF String SmsAttributes a 

Instances

Functor (SmsF i) 
Functor1 [*] SmsF 
Show a => Show (SmsF i a) 
ToXML a => ToXML (SmsF i a)