module JSDOM.Generated.AllVideoCapabilities
(getSourceType, getSourceId, getWidth, getWidthUnsafe,
getWidthUnchecked, getHeight, getHeightUnsafe, getHeightUnchecked,
getFrameRate, getFrameRateUnsafe, getFrameRateUnchecked,
getAspectRatio, getAspectRatioUnsafe, getAspectRatioUnchecked,
getFacingMode, AllVideoCapabilities(..), gTypeAllVideoCapabilities)
where
import Prelude ((.), (==), (>>=), return, IO, Int, Float, Double, Bool(..), Maybe, maybe, fromIntegral, round, realToFrac, fmap, Show, Read, Eq, Ord, Maybe(..))
import qualified Prelude (error)
import Data.Typeable (Typeable)
import Language.Javascript.JSaddle (JSM(..), JSVal(..), JSString, strictEqual, toJSVal, valToStr, valToNumber, valToBool, js, jss, jsf, jsg, function, new, array)
import Data.Int (Int64)
import Data.Word (Word, Word64)
import JSDOM.Types
import Control.Applicative ((<$>))
import Control.Monad (void)
import Control.Lens.Operators ((^.))
import JSDOM.EventTargetClosures (EventName, unsafeEventName)
import JSDOM.Enums
getSourceType ::
(MonadDOM m, FromJSString result) =>
AllVideoCapabilities -> m [result]
getSourceType self
= liftDOM ((self ^. js "sourceType") >>= fromJSArrayUnchecked)
getSourceId ::
(MonadDOM m, FromJSString result) =>
AllVideoCapabilities -> m [result]
getSourceId self
= liftDOM ((self ^. js "sourceId") >>= fromJSArrayUnchecked)
getWidth ::
(MonadDOM m) => AllVideoCapabilities -> m (Maybe CapabilityRange)
getWidth self = liftDOM ((self ^. js "width") >>= fromJSVal)
getWidthUnsafe ::
(MonadDOM m, HasCallStack) =>
AllVideoCapabilities -> m CapabilityRange
getWidthUnsafe self
= liftDOM
(((self ^. js "width") >>= fromJSVal) >>=
maybe (Prelude.error "Nothing to return") return)
getWidthUnchecked ::
(MonadDOM m) => AllVideoCapabilities -> m CapabilityRange
getWidthUnchecked self
= liftDOM ((self ^. js "width") >>= fromJSValUnchecked)
getHeight ::
(MonadDOM m) => AllVideoCapabilities -> m (Maybe CapabilityRange)
getHeight self = liftDOM ((self ^. js "height") >>= fromJSVal)
getHeightUnsafe ::
(MonadDOM m, HasCallStack) =>
AllVideoCapabilities -> m CapabilityRange
getHeightUnsafe self
= liftDOM
(((self ^. js "height") >>= fromJSVal) >>=
maybe (Prelude.error "Nothing to return") return)
getHeightUnchecked ::
(MonadDOM m) => AllVideoCapabilities -> m CapabilityRange
getHeightUnchecked self
= liftDOM ((self ^. js "height") >>= fromJSValUnchecked)
getFrameRate ::
(MonadDOM m) => AllVideoCapabilities -> m (Maybe CapabilityRange)
getFrameRate self
= liftDOM ((self ^. js "frameRate") >>= fromJSVal)
getFrameRateUnsafe ::
(MonadDOM m, HasCallStack) =>
AllVideoCapabilities -> m CapabilityRange
getFrameRateUnsafe self
= liftDOM
(((self ^. js "frameRate") >>= fromJSVal) >>=
maybe (Prelude.error "Nothing to return") return)
getFrameRateUnchecked ::
(MonadDOM m) => AllVideoCapabilities -> m CapabilityRange
getFrameRateUnchecked self
= liftDOM ((self ^. js "frameRate") >>= fromJSValUnchecked)
getAspectRatio ::
(MonadDOM m) => AllVideoCapabilities -> m (Maybe CapabilityRange)
getAspectRatio self
= liftDOM ((self ^. js "aspectRatio") >>= fromJSVal)
getAspectRatioUnsafe ::
(MonadDOM m, HasCallStack) =>
AllVideoCapabilities -> m CapabilityRange
getAspectRatioUnsafe self
= liftDOM
(((self ^. js "aspectRatio") >>= fromJSVal) >>=
maybe (Prelude.error "Nothing to return") return)
getAspectRatioUnchecked ::
(MonadDOM m) => AllVideoCapabilities -> m CapabilityRange
getAspectRatioUnchecked self
= liftDOM ((self ^. js "aspectRatio") >>= fromJSValUnchecked)
getFacingMode ::
(MonadDOM m, FromJSString result) =>
AllVideoCapabilities -> m [result]
getFacingMode self
= liftDOM ((self ^. js "facingMode") >>= fromJSArrayUnchecked)