opentok-0.0.5: An OpenTok SDK for Haskell

Safe HaskellNone
LanguageHaskell2010

OpenTok.Session

Contents

Synopsis

Documentation

data ArchiveMode Source #

Manual, as it implies, requires archives to be manually started and stopped. Always means that archives will automatically be created.

Constructors

Manual 
Always 
Instances
Eq ArchiveMode Source # 
Instance details

Defined in OpenTok.Session

Data ArchiveMode Source # 
Instance details

Defined in OpenTok.Session

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> ArchiveMode -> c ArchiveMode #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c ArchiveMode #

toConstr :: ArchiveMode -> Constr #

dataTypeOf :: ArchiveMode -> DataType #

dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c ArchiveMode) #

dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c ArchiveMode) #

gmapT :: (forall b. Data b => b -> b) -> ArchiveMode -> ArchiveMode #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> ArchiveMode -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> ArchiveMode -> r #

gmapQ :: (forall d. Data d => d -> u) -> ArchiveMode -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> ArchiveMode -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> ArchiveMode -> m ArchiveMode #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> ArchiveMode -> m ArchiveMode #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> ArchiveMode -> m ArchiveMode #

Show ArchiveMode Source # 
Instance details

Defined in OpenTok.Session

Generic ArchiveMode Source # 
Instance details

Defined in OpenTok.Session

Associated Types

type Rep ArchiveMode :: * -> * #

ToJSON ArchiveMode Source # 
Instance details

Defined in OpenTok.Session

FromJSON ArchiveMode Source # 
Instance details

Defined in OpenTok.Session

type Rep ArchiveMode Source # 
Instance details

Defined in OpenTok.Session

type Rep ArchiveMode = D1 (MetaData "ArchiveMode" "OpenTok.Session" "opentok-0.0.5-IcL1zYCkr65C5B0v2oYVUO" False) (C1 (MetaCons "Manual" PrefixI False) (U1 :: * -> *) :+: C1 (MetaCons "Always" PrefixI False) (U1 :: * -> *))

data MediaMode Source #

Relayed sessions will attempt to use peer-to-peer (p2p) connections.

Routed sessions will use the OpenTok Media Router

Constructors

Relayed 
Routed 
Instances
Eq MediaMode Source # 
Instance details

Defined in OpenTok.Session

Data MediaMode Source # 
Instance details

Defined in OpenTok.Session

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> MediaMode -> c MediaMode #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c MediaMode #

toConstr :: MediaMode -> Constr #

dataTypeOf :: MediaMode -> DataType #

dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c MediaMode) #

dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c MediaMode) #

gmapT :: (forall b. Data b => b -> b) -> MediaMode -> MediaMode #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> MediaMode -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> MediaMode -> r #

gmapQ :: (forall d. Data d => d -> u) -> MediaMode -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> MediaMode -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> MediaMode -> m MediaMode #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> MediaMode -> m MediaMode #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> MediaMode -> m MediaMode #

Show MediaMode Source # 
Instance details

Defined in OpenTok.Session

Generic MediaMode Source # 
Instance details

Defined in OpenTok.Session

Associated Types

type Rep MediaMode :: * -> * #

ToJSON MediaMode Source # 
Instance details

Defined in OpenTok.Session

FromJSON MediaMode Source # 
Instance details

Defined in OpenTok.Session

type Rep MediaMode Source # 
Instance details

Defined in OpenTok.Session

type Rep MediaMode = D1 (MetaData "MediaMode" "OpenTok.Session" "opentok-0.0.5-IcL1zYCkr65C5B0v2oYVUO" False) (C1 (MetaCons "Relayed" PrefixI False) (U1 :: * -> *) :+: C1 (MetaCons "Routed" PrefixI False) (U1 :: * -> *))

data SessionOptions Source #

Defines options for an OpenTok Session

MediaMode specifies how clients in the session will send audio and video streams.

ArchiveMode specifies how archives will be created.

An IPv4 address may be provided as a location hint which will be used in selecting an OpenTok Media Router for the session.

Instances
Show SessionOptions Source # 
Instance details

Defined in OpenTok.Session

Generic SessionOptions Source # 
Instance details

Defined in OpenTok.Session

Associated Types

type Rep SessionOptions :: * -> * #

ToJSON SessionOptions Source # 
Instance details

Defined in OpenTok.Session

type Rep SessionOptions Source # 
Instance details

Defined in OpenTok.Session

type Rep SessionOptions = D1 (MetaData "SessionOptions" "OpenTok.Session" "opentok-0.0.5-IcL1zYCkr65C5B0v2oYVUO" False) (C1 (MetaCons "SessionOptions" PrefixI True) (S1 (MetaSel (Just "_mediaMode") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 MediaMode) :*: (S1 (MetaSel (Just "_archiveMode") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 ArchiveMode) :*: S1 (MetaSel (Just "_location") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (Maybe IPv4)))))

data Session Source #

An OpenTok Session

Session {
  apiKey :: String,
  sessionId :: String,
  mediaMode :: MediaMode,
  archiveMode :: ArchiveMode
}
Instances
Show Session Source # 
Instance details

Defined in OpenTok.Session

sessionOpts :: SessionOptions Source #

Default Session options

SessionOptions
  { _mediaMode: Relayed
  , _archiveMode: Manual
  , _location: Nothing
}

create :: Client -> SessionOptions -> IO (Either OTError Session) Source #

Create a new OpenTok Session

Orphan instances

ToJSON IPv4 Source # 
Instance details