Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- pattern SpiderBehavior :: Behavior x a -> Behavior (SpiderTimeline x) a
- unSpiderBehavior :: Behavior (SpiderTimeline x) a -> Behavior x a
- pattern SpiderEvent :: Event x a -> Event (SpiderTimeline x) a
- unSpiderEvent :: Event (SpiderTimeline x) a -> Event x a
- pattern SpiderDynamic :: DynamicS x (Identity a) -> Dynamic (SpiderTimeline x) a
- unSpiderDynamic :: Dynamic (SpiderTimeline x) a -> DynamicS x (Identity a)
- pattern SpiderIncremental :: DynamicS x p -> Incremental (SpiderTimeline x) p
- unSpiderIncremental :: Incremental (SpiderTimeline x) p -> DynamicS x p
- newtype ReadPhase x a = ReadPhase (ResultM x a)
- newtype SpiderHostFrame (x :: Type) a = SpiderHostFrame {
- runSpiderHostFrame :: EventM x a
- newtype SpiderHost (x :: Type) a = SpiderHost {
- unSpiderHost :: IO a
- data SpiderEventHandle x a = SpiderEventHandle {}
- data RootTrigger x a = GCompare k => RootTrigger (WeakBag (Subscriber x a), IORef (DMap k Identity), k a)
- newtype SpiderPushM (x :: Type) a = SpiderPushM (ComputeM x a)
- type ComputeM = EventM
- newtype SpiderPullM (x :: Type) a = SpiderPullM (BehaviorM x a)
- data LocalSpiderTimeline (x :: Type) s
- type SpiderEnv = SpiderTimeline
- type Spider = SpiderTimeline Global
- data SpiderTimeline x
- data SomeSwitchSubscribed x = SomeSwitchSubscribed (SwitchSubscribed x a)
- newtype Height = Height {}
- newtype EventSelectorG x k v = EventSelectorG {}
- newtype EventSelector x k = EventSelector {}
- data Merge x k v s = Merge {
- _merge_parentsRef :: !(IORef (DMap k s))
- _merge_heightBagRef :: !(IORef HeightBag)
- _merge_heightRef :: !(IORef Height)
- _merge_sub :: !(Subscriber x (DMap k v))
- _merge_accumRef :: !(IORef (DMap k v))
- type MergeDestroyFunc k s = DMap k s -> IO ()
- type MergeInitFunc k v q x s = DMap k q -> (forall a. EventM x (k a) -> Subscriber x (v a)) -> EventM x (DMap k v, [Height], DMap k s)
- type MergeGetSubscription x s = forall a. s a -> EventSubscription x
- type MergeUpdateFunc k v x p s = (forall a. EventM x (k a) -> Subscriber x (v a)) -> IORef HeightBag -> DMap k s -> p -> EventM x ([EventSubscription x], DMap k s)
- data FanInt x a = FanInt {
- _fanInt_subscribers :: !(FastMutableIntMap (FastWeakBag (Subscriber x a)))
- _fanInt_subscriptionRef :: !(IORef (EventSubscription x))
- _fanInt_occRef :: !(IORef (IntMap a))
- newtype EventSelectorInt x a = EventSelectorInt {}
- data SomeResetCoincidence x = SomeResetCoincidence !(EventSubscription x) !(Maybe (CoincidenceSubscribed x a))
- data EventLoopException = EventLoopException
- type CanTrace x m = (HasSpiderTimeline x, MonadIO m)
- type WeakList a = [Weak a]
- data SomeAssignment x = SomeAssignment !(IORef a) !(IORef [Weak (Invalidator x)]) a
- newtype RootClear k = RootClear (IORef (DMap k Identity))
- newtype IntClear a = IntClear (IORef (IntMap a))
- newtype Clear a = Clear (IORef (Maybe a))
- type ResultM = EventM
- newtype Dyn (x :: Type) p = Dyn {}
- data DynType x p
- = UnsafeDyn !(BehaviorM x (PatchTarget p), Event x p)
- | BuildDyn !(EventM x (PatchTarget p), Event x p)
- | HoldDyn !(Hold x p)
- data Coincidence x a = Coincidence {
- coincidenceParent :: !(Event x (Event x a))
- coincidenceSubscribed :: !(IORef (Maybe (CoincidenceSubscribed x a)))
- data CoincidenceSubscribed x a = CoincidenceSubscribed {
- coincidenceSubscribedCachedSubscribed :: !(IORef (Maybe (CoincidenceSubscribed x a)))
- coincidenceSubscribedOccurrence :: !(IORef (Maybe a))
- coincidenceSubscribedSubscribers :: !(WeakBag (Subscriber x a))
- coincidenceSubscribedHeight :: !(IORef Height)
- coincidenceSubscribedOuter :: (Subscriber x (Event x a))
- coincidenceSubscribedOuterParent :: !(EventSubscription x)
- coincidenceSubscribedInnerParent :: !(IORef (Maybe (EventSubscribed x)))
- coincidenceSubscribedWeakSelf :: !(IORef (Weak (CoincidenceSubscribed x a)))
- data Switch x a = Switch {
- switchParent :: !(Behavior x (Event x a))
- switchSubscribed :: !(IORef (Maybe (SwitchSubscribed x a)))
- data SwitchSubscribed x a = SwitchSubscribed {
- switchSubscribedCachedSubscribed :: !(IORef (Maybe (SwitchSubscribed x a)))
- switchSubscribedOccurrence :: !(IORef (Maybe a))
- switchSubscribedHeight :: !(IORef Height)
- switchSubscribedSubscribers :: !(WeakBag (Subscriber x a))
- switchSubscribedOwnInvalidator :: !(Invalidator x)
- switchSubscribedOwnWeakInvalidator :: !(IORef (Weak (Invalidator x)))
- switchSubscribedBehaviorParents :: !(IORef [SomeBehaviorSubscribed x])
- switchSubscribedParent :: !(Behavior x (Event x a))
- switchSubscribedCurrentParent :: !(IORef (EventSubscription x))
- switchSubscribedWeakSelf :: !(IORef (Weak (SwitchSubscribed x a)))
- data Fan x k v = Fan {
- fanParent :: !(Event x (DMap k v))
- fanSubscribed :: !(IORef (Maybe (FanSubscribed x k v)))
- data FanSubscribed x k v = FanSubscribed {
- fanSubscribedCachedSubscribed :: !(IORef (Maybe (FanSubscribed x k v)))
- fanSubscribedOccurrence :: !(IORef (Maybe (DMap k v)))
- fanSubscribedSubscribers :: !(IORef (DMap k (FanSubscribedChildren x k v)))
- fanSubscribedParent :: !(EventSubscription x)
- data FanSubscribedChildren x k v a = FanSubscribedChildren {
- _fanSubscribedChildren_list :: !(WeakBag (Subscriber x (v a)))
- _fanSubscribedChildren_self :: !(k a, FanSubscribed x k v)
- _fanSubscribedChildren_weakSelf :: !(IORef (Weak (k a, FanSubscribed x k v)))
- data HeightBag = HeightBag {
- _heightBag_size :: !Int
- _heightBag_contents :: !(IntMap Word)
- data MergeSubscribedParentWithMove x k a = MergeSubscribedParentWithMove {}
- newtype MergeSubscribedParent x a = MergeSubscribedParent {}
- newtype EventM x a = EventM {}
- newtype SomeMergeInit x = SomeMergeInit {
- unSomeMergeInit :: EventM x ()
- data SomeMergeUpdate x = SomeMergeUpdate {
- _someMergeUpdate_update :: !(EventM x [EventSubscription x])
- _someMergeUpdate_invalidateHeight :: !(IO ())
- _someMergeUpdate_recalculateHeight :: !(IO ())
- data SomeDynInit x = Patch p => SomeDynInit !(Dyn x p)
- data SomeHoldInit x = Patch p => SomeHoldInit !(Hold x p)
- data Root x k = Root {
- rootOccurrence :: !(IORef (DMap k Identity))
- rootSubscribed :: !(IORef (DMap k (RootSubscribed x)))
- rootInit :: !(forall a. k a -> RootTrigger x a -> IO (IO ()))
- data RootSubscribed x a = GCompare k => RootSubscribed {
- rootSubscribedKey :: !(k a)
- rootSubscribedCachedSubscribed :: !(IORef (DMap k (RootSubscribed x)))
- rootSubscribedSubscribers :: !(WeakBag (Subscriber x a))
- rootSubscribedOccurrence :: !(IO (Maybe a))
- rootSubscribedUninit :: IO ()
- rootSubscribedWeakSelf :: !(IORef (Weak (RootSubscribed x a)))
- data Invalidator x
- = InvalidatorPull (Pull x a)
- | InvalidatorSwitch (SwitchSubscribed x a)
- data Pull x a = Pull {
- pullValue :: !(IORef (Maybe (PullSubscribed x a)))
- pullCompute :: !(BehaviorM x a)
- data PullSubscribed x a = PullSubscribed {
- pullSubscribedValue :: !a
- pullSubscribedInvalidators :: !(IORef [Weak (Invalidator x)])
- pullSubscribedOwnInvalidator :: !(Invalidator x)
- pullSubscribedParents :: ![SomeBehaviorSubscribed x]
- newtype SomeBehaviorSubscribed x = SomeBehaviorSubscribed (Some (BehaviorSubscribed x))
- data BehaviorSubscribed x a
- = BehaviorSubscribedHold (Hold x p)
- | BehaviorSubscribedPull (PullSubscribed x a)
- newtype BehaviorM x a = BehaviorM {
- unBehaviorM :: ReaderIO (BehaviorEnv x) a
- type BehaviorEnv x = (Maybe (Weak (Invalidator x), IORef [SomeBehaviorSubscribed x]), IORef [SomeHoldInit x])
- class HasSpiderTimeline x where
- class HasSpiderTimeline x => HasCurrentHeight x m | m -> x where
- getCurrentHeight :: m Height
- scheduleMerge :: Height -> EventM x () -> m ()
- class MonadIO m => Defer a m where
- getDeferralQueue :: m (IORef [a])
- data EventEnv x = EventEnv {
- eventEnvAssignments :: !(IORef [SomeAssignment x])
- eventEnvHoldInits :: !(IORef [SomeHoldInit x])
- eventEnvDynInits :: !(IORef [SomeDynInit x])
- eventEnvMergeUpdates :: !(IORef [SomeMergeUpdate x])
- eventEnvMergeInits :: !(IORef [SomeMergeInit x])
- eventEnvClears :: !(IORef [Some Clear])
- eventEnvIntClears :: !(IORef [Some IntClear])
- eventEnvRootClears :: !(IORef [Some RootClear])
- eventEnvCurrentHeight :: !(IORef Height)
- eventEnvResetCoincidences :: !(IORef [SomeResetCoincidence x])
- eventEnvDelayedMerges :: !(IORef (IntMap [EventM x ()]))
- data SpiderTimelineEnv' x = SpiderTimelineEnv {
- _spiderTimeline_lock :: !(MVar ())
- _spiderTimeline_eventEnv :: !(EventEnv x)
- newtype SpiderTimelineEnv x = STE {
- unSTE :: SpiderTimelineEnv' x
- data Global
- data Hold x p = Hold {
- holdValue :: !(IORef (PatchTarget p))
- holdInvalidators :: !(IORef [Weak (Invalidator x)])
- holdEvent :: Event x p
- holdParent :: !(IORef (Maybe (EventSubscription x)))
- data Dynamic x target p = Dynamic {
- dynamicCurrent :: !(Behavior x target)
- dynamicUpdated :: Event x p
- type DynamicS x p = Dynamic x (PatchTarget p) p
- newtype Behavior x a = Behavior {
- readBehaviorTracked :: BehaviorM x a
- data EventSubscribed x = EventSubscribed {}
- data Subscriber x a = Subscriber {
- subscriberPropagate :: !(a -> EventM x ())
- subscriberInvalidateHeight :: !(Height -> IO ())
- subscriberRecalculateHeight :: !(Height -> IO ())
- data CacheSubscribed x a = CacheSubscribed {
- _cacheSubscribed_subscribers :: !(FastWeakBag (Subscriber x a))
- _cacheSubscribed_parent :: !(EventSubscription x)
- _cacheSubscribed_occurrence :: !(IORef (Maybe a))
- newtype Event x a = Event {
- unEvent :: Subscriber x a -> EventM x (EventSubscription x, Maybe a)
- data EventSubscription x = EventSubscription {
- _eventSubscription_unsubscribe :: !(IO ())
- _eventSubscription_subscribed :: !(EventSubscribed x)
- debugStrLn :: String -> IO ()
- debugPropagate :: Bool
- debugInvalidateHeight :: Bool
- debugInvalidate :: Bool
- showNodeId :: a -> String
- showNodeId' :: Int -> String
- unsubscribe :: EventSubscription x -> IO ()
- subscribeAndRead :: Event x a -> Subscriber x a -> EventM x (EventSubscription x, Maybe a)
- pushCheap :: HasSpiderTimeline x => (a -> ComputeM x (Maybe b)) -> Event x a -> Event x b
- terminalSubscriber :: (a -> EventM x ()) -> Subscriber x a
- subscribeAndReadHead :: HasSpiderTimeline x => Event x a -> Subscriber x a -> EventM x (EventSubscription x, Maybe a)
- headE :: (MonadIO m, Defer (SomeMergeInit x) m, HasSpiderTimeline x) => Event x a -> m (Event x a)
- cacheEvent :: forall x a. HasSpiderTimeline x => Event x a -> Event x a
- cacheSubscription :: Subscriber x a -> IORef (FastWeak (CacheSubscribed x a)) -> FastWeakTicket (CacheSubscribed x a) -> IO (EventSubscription x, Maybe a)
- subscribe :: Event x a -> Subscriber x a -> EventM x (EventSubscription x)
- wrap :: MonadIO m => (t -> EventSubscribed x) -> (Subscriber x a -> m (WeakBagTicket, t, Maybe a)) -> Subscriber x a -> m (EventSubscription x, Maybe a)
- eventRoot :: (GCompare k, HasSpiderTimeline x) => k a -> Root x k -> Event x a
- subscribeAndReadNever :: EventM x (EventSubscription x, Maybe a)
- eventNever :: Event x a
- eventFan :: (GCompare k, HasSpiderTimeline x) => k a -> Fan x k v -> Event x (v a)
- eventSwitch :: HasSpiderTimeline x => Switch x a -> Event x a
- eventCoincidence :: HasSpiderTimeline x => Coincidence x a -> Event x a
- eventHold :: Hold x p -> Event x p
- eventDyn :: (HasSpiderTimeline x, Patch p) => Dyn x p -> Event x p
- subscribeCoincidenceInner :: HasSpiderTimeline x => Event x a -> Height -> CoincidenceSubscribed x a -> EventM x (Maybe a, Height, EventSubscribed x)
- newSubscriberHold :: (HasSpiderTimeline x, Patch p) => Hold x p -> IO (Subscriber x p)
- newSubscriberFan :: forall x k v. (HasSpiderTimeline x, GCompare k) => FanSubscribed x k v -> IO (Subscriber x (DMap k v))
- newSubscriberSwitch :: forall x a. HasSpiderTimeline x => SwitchSubscribed x a -> IO (Subscriber x a)
- newSubscriberCoincidenceOuter :: forall x b. HasSpiderTimeline x => CoincidenceSubscribed x b -> IO (Subscriber x (Event x b))
- newSubscriberCoincidenceInner :: forall x a. HasSpiderTimeline x => CoincidenceSubscribed x a -> IO (Subscriber x a)
- invalidateSubscriberHeight :: Height -> Subscriber x a -> IO ()
- recalculateSubscriberHeight :: Height -> Subscriber x a -> IO ()
- propagate :: forall x a. HasSpiderTimeline x => a -> WeakBag (Subscriber x a) -> EventM x ()
- propagateFast :: forall x a. HasSpiderTimeline x => a -> FastWeakBag (Subscriber x a) -> EventM x ()
- toAny :: a -> Any
- eventSubscribedRoot :: RootSubscribed x a -> EventSubscribed x
- eventSubscribedNever :: EventSubscribed x
- eventSubscribedFan :: FanSubscribed x k v -> EventSubscribed x
- eventSubscribedSwitch :: SwitchSubscribed x a -> EventSubscribed x
- eventSubscribedCoincidence :: CoincidenceSubscribed x a -> EventSubscribed x
- getEventSubscribedHeight :: EventSubscribed x -> IO Height
- subscribeHoldEvent :: Hold x p -> Subscriber x p -> EventM x (EventSubscription x, Maybe p)
- behaviorHold :: Hold x p -> Behavior x (PatchTarget p)
- behaviorHoldIdentity :: Hold x (Identity a) -> Behavior x a
- behaviorConst :: a -> Behavior x a
- behaviorPull :: Pull x a -> Behavior x a
- behaviorDyn :: Patch p => Dyn x p -> Behavior x (PatchTarget p)
- readHoldTracked :: Hold x p -> BehaviorM x (PatchTarget p)
- readBehaviorUntracked :: Defer (SomeHoldInit x) m => Behavior x a -> m a
- dynamicHold :: Hold x p -> DynamicS x p
- dynamicHoldIdentity :: Hold x (Identity a) -> DynamicS x (Identity a)
- dynamicConst :: PatchTarget p -> DynamicS x p
- dynamicDyn :: (HasSpiderTimeline x, Patch p) => Dyn x p -> DynamicS x p
- dynamicDynIdentity :: HasSpiderTimeline x => Dyn x (Identity a) -> DynamicS x (Identity a)
- globalSpiderTimelineEnv :: SpiderTimelineEnv Global
- runEventM :: EventM x a -> IO a
- asksEventEnv :: forall x a. HasSpiderTimeline x => (EventEnv x -> a) -> EventM x a
- defer :: Defer a m => a -> m ()
- putCurrentHeight :: HasSpiderTimeline x => Height -> EventM x ()
- scheduleClear :: Defer (Some Clear) m => IORef (Maybe a) -> m ()
- scheduleIntClear :: Defer (Some IntClear) m => IORef (IntMap a) -> m ()
- scheduleRootClear :: Defer (Some RootClear) m => IORef (DMap k Identity) -> m ()
- hold :: (Patch p, Defer (SomeHoldInit x) m) => PatchTarget p -> Event x p -> m (Hold x p)
- getHoldEventSubscription :: forall p x. (HasSpiderTimeline x, Patch p) => Hold x p -> EventM x (EventSubscription x)
- heightBagEmpty :: HeightBag
- heightBagSize :: HeightBag -> Int
- heightBagFromList :: [Height] -> HeightBag
- heightBagAdd :: Height -> HeightBag -> HeightBag
- heightBagRemove :: Height -> HeightBag -> HeightBag
- heightBagRemoveMaybe :: Height -> HeightBag -> Maybe HeightBag
- heightBagMax :: HeightBag -> Height
- heightBagVerify :: HeightBag -> HeightBag
- newInvalidatorSwitch :: SwitchSubscribed x a -> IO (Invalidator x)
- newInvalidatorPull :: Pull x a -> IO (Invalidator x)
- newMapDyn :: HasSpiderTimeline x => (a -> b) -> DynamicS x (Identity a) -> DynamicS x (Identity b)
- zipDynWith :: HasSpiderTimeline x => (a -> b -> c) -> DynamicS x (Identity a) -> DynamicS x (Identity b) -> DynamicS x (Identity c)
- buildDynamic :: (Defer (SomeDynInit x) m, Patch p) => EventM x (PatchTarget p) -> Event x p -> m (Dyn x p)
- unsafeBuildDynamic :: BehaviorM x (PatchTarget p) -> Event x p -> Dyn x p
- push :: HasSpiderTimeline x => (a -> ComputeM x (Maybe b)) -> Event x a -> Event x b
- pull :: BehaviorM x a -> Behavior x a
- switch :: HasSpiderTimeline x => Behavior x (Event x a) -> Event x a
- coincidence :: HasSpiderTimeline x => Event x (Event x a) -> Event x a
- run :: forall x b. HasSpiderTimeline x => [DSum (RootTrigger x) Identity] -> ResultM x b -> SpiderHost x b
- scheduleMerge' :: HasSpiderTimeline x => Height -> IORef Height -> EventM x () -> EventM x ()
- debugFinalize :: Bool
- mkWeakPtrWithDebug :: a -> String -> IO (Weak a)
- withIncreasedDepth :: proxy x -> m a -> m a
- tracePropagate :: CanTrace x m => proxy x -> String -> m ()
- traceInvalidate :: String -> IO ()
- traceInvalidateHeight :: String -> IO ()
- debugSubscriber :: String -> Subscriber x a -> IO (Subscriber x a)
- debugSubscriber' :: String -> Subscriber x a -> Subscriber x a
- trace :: CanTrace x m => proxy x -> String -> m ()
- traceM :: CanTrace x m => proxy x -> m String -> m ()
- whoCreatedIORef :: IORef a -> IO [String]
- groupByHead :: Eq a => [NonEmpty a] -> [(a, NonEmpty [a])]
- listsToForest :: Eq a => [[a]] -> Forest a
- showStacks :: [[String]] -> String
- filterStack :: String -> [String] -> [String]
- propagateSubscriberHold :: forall x p. (HasSpiderTimeline x, Patch p) => Hold x p -> p -> EventM x ()
- runBehaviorM :: BehaviorM x a -> Maybe (Weak (Invalidator x), IORef [SomeBehaviorSubscribed x]) -> IORef [SomeHoldInit x] -> IO a
- askInvalidator :: BehaviorM x (Maybe (Weak (Invalidator x)))
- askParentsRef :: BehaviorM x (Maybe (IORef [SomeBehaviorSubscribed x]))
- askBehaviorHoldInits :: BehaviorM x (IORef [SomeHoldInit x])
- getDynHold :: (Defer (SomeHoldInit x) m, Patch p) => Dyn x p -> m (Hold x p)
- zeroRef :: IORef Height
- getRootSubscribed :: forall k x a. (GCompare k, HasSpiderTimeline x) => k a -> Root x k -> Subscriber x a -> IO (WeakBagTicket, RootSubscribed x a, Maybe a)
- cleanupRootSubscribed :: RootSubscribed x a -> IO ()
- subscribeRootSubscribed :: RootSubscribed x a -> Subscriber x a -> IO WeakBagTicket
- newFanInt :: IO (FanInt x a)
- fanInt :: HasSpiderTimeline x => Event x (IntMap a) -> EventSelectorInt x a
- fanIntSubscribed :: FastWeakBagTicket k -> FanInt x a -> IO (EventSubscribed x)
- getFanSubscribed :: (HasSpiderTimeline x, GCompare k) => k a -> Fan x k v -> Subscriber x (v a) -> EventM x (WeakBagTicket, FanSubscribed x k v, Maybe (v a))
- cleanupFanSubscribed :: GCompare k => (k a, FanSubscribed x k v) -> IO ()
- subscribeFanSubscribed :: GCompare k => k a -> FanSubscribed x k v -> Subscriber x (v a) -> IO WeakBagTicket
- getSwitchSubscribed :: HasSpiderTimeline x => Switch x a -> Subscriber x a -> EventM x (WeakBagTicket, SwitchSubscribed x a, Maybe a)
- cleanupSwitchSubscribed :: SwitchSubscribed x a -> IO ()
- subscribeSwitchSubscribed :: SwitchSubscribed x a -> Subscriber x a -> IO WeakBagTicket
- getCoincidenceSubscribed :: forall x a. HasSpiderTimeline x => Coincidence x a -> Subscriber x a -> EventM x (WeakBagTicket, CoincidenceSubscribed x a, Maybe a)
- cleanupCoincidenceSubscribed :: CoincidenceSubscribed x a -> IO ()
- subscribeCoincidenceSubscribed :: CoincidenceSubscribed x a -> Subscriber x a -> IO WeakBagTicket
- mergeG :: forall k q x v. (HasSpiderTimeline x, GCompare k) => (forall a. q a -> Event x (v a)) -> DynamicS x (PatchDMap k q) -> Event x (DMap k v)
- mergeWithMove :: forall k v q x. (HasSpiderTimeline x, GCompare k) => (forall a. q a -> Event x (v a)) -> DynamicS x (PatchDMapWithMove k q) -> Event x (DMap k v)
- mergeCheap :: forall k x q v. (HasSpiderTimeline x, GCompare k) => (forall a. q a -> Event x (v a)) -> DynamicS x (PatchDMap k q) -> Event x (DMap k v)
- mergeCheapWithMove :: forall k x v q. (HasSpiderTimeline x, GCompare k) => (forall a. q a -> Event x (v a)) -> DynamicS x (PatchDMapWithMove k q) -> Event x (DMap k v)
- invalidateMergeHeight :: Merge x k v s -> IO ()
- invalidateMergeHeight' :: IORef Height -> Subscriber x a -> IO ()
- revalidateMergeHeight :: Merge x k v s -> IO ()
- scheduleMergeSelf :: HasSpiderTimeline x => Merge x k v s -> Height -> EventM x ()
- checkCycle :: HasSpiderTimeline x => EventSubscribed x -> EventM x ()
- mergeSubscriber :: forall x k v s a. (HasSpiderTimeline x, GCompare k) => EventSubscribed x -> Merge x k v s -> EventM x (k a) -> Subscriber x (v a)
- updateMerge :: (HasSpiderTimeline x, GCompare k) => EventSubscribed x -> Merge x k v s -> MergeUpdateFunc k v x p s -> p -> SomeMergeUpdate x
- mergeGCheap' :: forall k v x p s q. (HasSpiderTimeline x, GCompare k, PatchTarget p ~ DMap k q) => MergeGetSubscription x s -> MergeInitFunc k v q x s -> MergeUpdateFunc k v x p s -> MergeDestroyFunc k s -> DynamicS x p -> Event x (DMap k v)
- mergeInt :: forall x a. HasSpiderTimeline x => DynamicS x (PatchIntMap (Event x a)) -> Event x (IntMap a)
- mergeIntCheap :: forall x a. HasSpiderTimeline x => DynamicS x (PatchIntMap (Event x a)) -> Event x (IntMap a)
- fanG :: (HasSpiderTimeline x, GCompare k) => Event x (DMap k v) -> EventSelectorG x k v
- runHoldInits :: HasSpiderTimeline x => IORef [SomeHoldInit x] -> IORef [SomeDynInit x] -> IORef [SomeMergeInit x] -> EventM x ()
- initHold :: HasSpiderTimeline x => SomeHoldInit x -> EventM x ()
- initDyn :: HasSpiderTimeline x => SomeDynInit x -> EventM x ()
- newEventEnv :: IO (EventEnv x)
- clearEventEnv :: EventEnv x -> IO ()
- runFrame :: forall x a. HasSpiderTimeline x => EventM x a -> SpiderHost x a
- zeroHeight :: Height
- invalidHeight :: Height
- succHeight :: Height -> Height
- invalidateCoincidenceHeight :: CoincidenceSubscribed x a -> IO ()
- updateSwitchHeight :: Height -> SwitchSubscribed x a -> IO ()
- recalculateCoincidenceHeight :: CoincidenceSubscribed x a -> IO ()
- calculateSwitchHeight :: SwitchSubscribed x a -> IO Height
- calculateCoincidenceHeight :: CoincidenceSubscribed x a -> IO Height
- invalidate :: IORef [SomeSwitchSubscribed x] -> WeakList (Invalidator x) -> IO (WeakList (Invalidator x))
- newJoinDyn :: HasSpiderTimeline x => DynamicS x (Identity (DynamicS x (Identity a))) -> Dyn x (Identity a)
- mapDynamicSpider :: HasSpiderTimeline x => (a -> b) -> Dynamic (SpiderTimeline x) a -> Dynamic (SpiderTimeline x) b
- holdSpiderEventM :: HasSpiderTimeline x => a -> Event (SpiderTimeline x) a -> EventM x (Behavior (SpiderTimeline x) a)
- holdDynSpiderEventM :: HasSpiderTimeline x => a -> Event (SpiderTimeline x) a -> EventM x (Dynamic (SpiderTimeline x) a)
- holdIncrementalSpiderEventM :: (HasSpiderTimeline x, Patch p) => PatchTarget p -> Event (SpiderTimeline x) p -> EventM x (Incremental (SpiderTimeline x) p)
- buildDynamicSpiderEventM :: HasSpiderTimeline x => SpiderPushM x a -> Event (SpiderTimeline x) a -> EventM x (Dynamic (SpiderTimeline x) a)
- unsafeNewSpiderTimelineEnv :: forall x. IO (SpiderTimelineEnv x)
- newSpiderTimeline :: IO (Some SpiderTimelineEnv)
- localSpiderTimeline :: proxy s -> SpiderTimelineEnv x -> SpiderTimelineEnv (LocalSpiderTimeline x s)
- withSpiderTimeline :: (forall x. HasSpiderTimeline x => SpiderTimelineEnv x -> IO r) -> IO r
- runSpiderHost :: SpiderHost Global a -> IO a
- runSpiderHostForTimeline :: SpiderHost x a -> SpiderTimelineEnv x -> IO a
- newEventWithTriggerIO :: forall x a. HasSpiderTimeline x => (RootTrigger x a -> IO (IO ())) -> IO (Event x a)
- newFanEventWithTriggerIO :: (HasSpiderTimeline x, GCompare k) => (forall a. k a -> RootTrigger x a -> IO (IO ())) -> IO (EventSelector x k)
Documentation
pattern SpiderBehavior :: Behavior x a -> Behavior (SpiderTimeline x) a Source #
unSpiderBehavior :: Behavior (SpiderTimeline x) a -> Behavior x a Source #
pattern SpiderEvent :: Event x a -> Event (SpiderTimeline x) a Source #
unSpiderEvent :: Event (SpiderTimeline x) a -> Event x a Source #
pattern SpiderDynamic :: DynamicS x (Identity a) -> Dynamic (SpiderTimeline x) a Source #
unSpiderDynamic :: Dynamic (SpiderTimeline x) a -> DynamicS x (Identity a) Source #
pattern SpiderIncremental :: DynamicS x p -> Incremental (SpiderTimeline x) p Source #
unSpiderIncremental :: Incremental (SpiderTimeline x) p -> DynamicS x p Source #
newtype ReadPhase x a Source #
Instances
newtype SpiderHostFrame (x :: Type) a Source #
Instances
newtype SpiderHost (x :: Type) a Source #
The monad for actions that manipulate a Spider timeline identified by x
SpiderHost | |
|
Instances
data SpiderEventHandle x a Source #
data RootTrigger x a Source #
GCompare k => RootTrigger (WeakBag (Subscriber x a), IORef (DMap k Identity), k a) |
newtype SpiderPushM (x :: Type) a Source #
SpiderPushM (ComputeM x a) |
Instances
newtype SpiderPullM (x :: Type) a Source #
SpiderPullM (BehaviorM x a) |
Instances
data LocalSpiderTimeline (x :: Type) s Source #
Instances
Reifies s (SpiderTimelineEnv x) => HasSpiderTimeline (LocalSpiderTimeline x s) Source # | |
Defined in Reflex.Spider.Internal |
type SpiderEnv = SpiderTimeline Source #
Deprecated: Use SpiderTimelineEnv
instead
SpiderEnv
is the old name for SpiderTimeline
type Spider = SpiderTimeline Global Source #
The default, global Spider environment
data SpiderTimeline x Source #
Designates the default, global Spider timeline
Instances
data SomeSwitchSubscribed x Source #
newtype EventSelectorG x k v Source #
newtype EventSelector x k Source #
Merge | |
|
type MergeDestroyFunc k s = DMap k s -> IO () Source #
type MergeInitFunc k v q x s = DMap k q -> (forall a. EventM x (k a) -> Subscriber x (v a)) -> EventM x (DMap k v, [Height], DMap k s) Source #
type MergeGetSubscription x s = forall a. s a -> EventSubscription x Source #
type MergeUpdateFunc k v x p s = (forall a. EventM x (k a) -> Subscriber x (v a)) -> IORef HeightBag -> DMap k s -> p -> EventM x ([EventSubscription x], DMap k s) Source #
FanInt | |
|
newtype EventSelectorInt x a Source #
data SomeResetCoincidence x Source #
SomeResetCoincidence !(EventSubscription x) !(Maybe (CoincidenceSubscribed x a)) |
Instances
HasSpiderTimeline x => Defer (SomeResetCoincidence x) (EventM x) Source # | |
Defined in Reflex.Spider.Internal getDeferralQueue :: EventM x (IORef [SomeResetCoincidence x]) Source # |
data EventLoopException Source #
Instances
Show EventLoopException Source # | |
Defined in Reflex.Spider.Internal showsPrec :: Int -> EventLoopException -> ShowS # show :: EventLoopException -> String # showList :: [EventLoopException] -> ShowS # | |
Exception EventLoopException Source # | |
Defined in Reflex.Spider.Internal |
type CanTrace x m = (HasSpiderTimeline x, MonadIO m) Source #
data SomeAssignment x Source #
SomeAssignment !(IORef a) !(IORef [Weak (Invalidator x)]) a |
Instances
HasSpiderTimeline x => Defer (SomeAssignment x) (EventM x) Source # | |
Defined in Reflex.Spider.Internal getDeferralQueue :: EventM x (IORef [SomeAssignment x]) Source # |
Instances
HasSpiderTimeline x => Defer (Some RootClear) (EventM x) Source # | |
Defined in Reflex.Spider.Internal |
Instances
HasSpiderTimeline x => Defer (Some IntClear) (EventM x) Source # | |
Defined in Reflex.Spider.Internal |
Instances
HasSpiderTimeline x => Defer (Some Clear) (EventM x) Source # | |
Defined in Reflex.Spider.Internal |
UnsafeDyn !(BehaviorM x (PatchTarget p), Event x p) | |
BuildDyn !(EventM x (PatchTarget p), Event x p) | |
HoldDyn !(Hold x p) |
data Coincidence x a Source #
Coincidence | |
|
data CoincidenceSubscribed x a Source #
CoincidenceSubscribed | |
|
Switch | |
|
data SwitchSubscribed x a Source #
SwitchSubscribed | |
|
Fan | |
|
data FanSubscribed x k v Source #
FanSubscribed | |
|
data FanSubscribedChildren x k v a Source #
FanSubscribedChildren | |
|
HeightBag | |
|
data MergeSubscribedParentWithMove x k a Source #
newtype MergeSubscribedParent x a Source #
Instances
newtype SomeMergeInit x Source #
SomeMergeInit | |
|
Instances
HasSpiderTimeline x => Defer (SomeMergeInit x) (EventM x) Source # | |
Defined in Reflex.Spider.Internal getDeferralQueue :: EventM x (IORef [SomeMergeInit x]) Source # |
data SomeMergeUpdate x Source #
SomeMergeUpdate | |
|
Instances
HasSpiderTimeline x => Defer (SomeMergeUpdate x) (EventM x) Source # | |
Defined in Reflex.Spider.Internal getDeferralQueue :: EventM x (IORef [SomeMergeUpdate x]) Source # |
data SomeDynInit x Source #
Patch p => SomeDynInit !(Dyn x p) |
Instances
HasSpiderTimeline x => Defer (SomeDynInit x) (EventM x) Source # | |
Defined in Reflex.Spider.Internal getDeferralQueue :: EventM x (IORef [SomeDynInit x]) Source # |
data SomeHoldInit x Source #
Patch p => SomeHoldInit !(Hold x p) |
Instances
MonadReader (BehaviorEnv x) (BehaviorM x) Source # | |
Defined in Reflex.Spider.Internal ask :: BehaviorM x (BehaviorEnv x) # local :: (BehaviorEnv x -> BehaviorEnv x) -> BehaviorM x a -> BehaviorM x a # reader :: (BehaviorEnv x -> a) -> BehaviorM x a # | |
HasSpiderTimeline x => Defer (SomeHoldInit x) (EventM x) Source # | |
Defined in Reflex.Spider.Internal getDeferralQueue :: EventM x (IORef [SomeHoldInit x]) Source # | |
Defer (SomeHoldInit x) (BehaviorM x) Source # | |
Defined in Reflex.Spider.Internal getDeferralQueue :: BehaviorM x (IORef [SomeHoldInit x]) Source # |
Root | |
|
data RootSubscribed x a Source #
GCompare k => RootSubscribed | |
|
data Invalidator x Source #
InvalidatorPull (Pull x a) | |
InvalidatorSwitch (SwitchSubscribed x a) |
Instances
MonadReader (BehaviorEnv x) (BehaviorM x) Source # | |
Defined in Reflex.Spider.Internal ask :: BehaviorM x (BehaviorEnv x) # local :: (BehaviorEnv x -> BehaviorEnv x) -> BehaviorM x a -> BehaviorM x a # reader :: (BehaviorEnv x -> a) -> BehaviorM x a # |
Pull | |
|
data PullSubscribed x a Source #
PullSubscribed | |
|
newtype SomeBehaviorSubscribed x Source #
Instances
MonadReader (BehaviorEnv x) (BehaviorM x) Source # | |
Defined in Reflex.Spider.Internal ask :: BehaviorM x (BehaviorEnv x) # local :: (BehaviorEnv x -> BehaviorEnv x) -> BehaviorM x a -> BehaviorM x a # reader :: (BehaviorEnv x -> a) -> BehaviorM x a # |
data BehaviorSubscribed x a Source #
newtype BehaviorM x a Source #
BehaviorM | |
|
Instances
Monad (BehaviorM x) Source # | |
Functor (BehaviorM x) Source # | |
MonadFix (BehaviorM x) Source # | |
Defined in Reflex.Spider.Internal | |
Applicative (BehaviorM x) Source # | |
Defined in Reflex.Spider.Internal | |
MonadIO (BehaviorM x) Source # | |
Defined in Reflex.Spider.Internal | |
MonadReader (BehaviorEnv x) (BehaviorM x) Source # | |
Defined in Reflex.Spider.Internal ask :: BehaviorM x (BehaviorEnv x) # local :: (BehaviorEnv x -> BehaviorEnv x) -> BehaviorM x a -> BehaviorM x a # reader :: (BehaviorEnv x -> a) -> BehaviorM x a # | |
Defer (SomeHoldInit x) (BehaviorM x) Source # | |
Defined in Reflex.Spider.Internal getDeferralQueue :: BehaviorM x (IORef [SomeHoldInit x]) Source # |
type BehaviorEnv x = (Maybe (Weak (Invalidator x), IORef [SomeBehaviorSubscribed x]), IORef [SomeHoldInit x]) Source #
class HasSpiderTimeline x where Source #
spiderTimeline :: SpiderTimelineEnv x Source #
Retrieve the current SpiderTimelineEnv
Instances
HasSpiderTimeline Global Source # | |
Defined in Reflex.Spider.Internal | |
Reifies s (SpiderTimelineEnv x) => HasSpiderTimeline (LocalSpiderTimeline x s) Source # | |
Defined in Reflex.Spider.Internal |
class HasSpiderTimeline x => HasCurrentHeight x m | m -> x where Source #
getCurrentHeight :: m Height Source #
scheduleMerge :: Height -> EventM x () -> m () Source #
Instances
HasSpiderTimeline x => HasCurrentHeight x (EventM x) Source # | |
Defined in Reflex.Spider.Internal |
class MonadIO m => Defer a m where Source #
getDeferralQueue :: m (IORef [a]) Source #
Instances
EventEnv | |
|
data SpiderTimelineEnv' x Source #
SpiderTimelineEnv | |
|
newtype SpiderTimelineEnv x Source #
Stores all global data relevant to a particular Spider timeline; only one
value should exist for each type x
STE | |
|
Instances
GEq SpiderTimelineEnv Source # | |
Defined in Reflex.Spider.Internal geq :: SpiderTimelineEnv a -> SpiderTimelineEnv b -> Maybe (a :~: b) # | |
Eq (SpiderTimelineEnv x) Source # | |
Defined in Reflex.Spider.Internal (==) :: SpiderTimelineEnv x -> SpiderTimelineEnv x -> Bool # (/=) :: SpiderTimelineEnv x -> SpiderTimelineEnv x -> Bool # |
A statically allocated SpiderTimeline
Instances
HasSpiderTimeline Global Source # | |
Defined in Reflex.Spider.Internal |
Hold | |
|
data Dynamic x target p Source #
Dynamic | |
|
type DynamicS x p = Dynamic x (PatchTarget p) p Source #
Behavior | |
|
data EventSubscribed x Source #
data Subscriber x a Source #
Subscriber | |
|
data CacheSubscribed x a Source #
CacheSubscribed | |
|
Event | |
|
Instances
HasSpiderTimeline x => Functor (Event x) Source # | |
HasSpiderTimeline x => Semialign (Event x) Source # | |
HasSpiderTimeline x => Align (Event x) Source # | |
Defined in Reflex.Spider.Internal | |
HasSpiderTimeline x => Filterable (Event x) Source # | |
data EventSubscription x Source #
debugStrLn :: String -> IO () Source #
showNodeId :: a -> String Source #
showNodeId' :: Int -> String Source #
unsubscribe :: EventSubscription x -> IO () Source #
subscribeAndRead :: Event x a -> Subscriber x a -> EventM x (EventSubscription x, Maybe a) Source #
terminalSubscriber :: (a -> EventM x ()) -> Subscriber x a Source #
A subscriber that never triggers other Event
s
subscribeAndReadHead :: HasSpiderTimeline x => Event x a -> Subscriber x a -> EventM x (EventSubscription x, Maybe a) Source #
Subscribe to an Event only for the duration of one occurrence
headE :: (MonadIO m, Defer (SomeMergeInit x) m, HasSpiderTimeline x) => Event x a -> m (Event x a) Source #
cacheEvent :: forall x a. HasSpiderTimeline x => Event x a -> Event x a Source #
Construct an Event
whose value is guaranteed not to be recomputed
repeatedly
TODO: Try a caching strategy where we subscribe directly to the parent when there's only one subscriber, and then build our own FastWeakBag only when a second subscriber joins
cacheSubscription :: Subscriber x a -> IORef (FastWeak (CacheSubscribed x a)) -> FastWeakTicket (CacheSubscribed x a) -> IO (EventSubscription x, Maybe a) Source #
subscribe :: Event x a -> Subscriber x a -> EventM x (EventSubscription x) Source #
wrap :: MonadIO m => (t -> EventSubscribed x) -> (Subscriber x a -> m (WeakBagTicket, t, Maybe a)) -> Subscriber x a -> m (EventSubscription x, Maybe a) Source #
subscribeAndReadNever :: EventM x (EventSubscription x, Maybe a) Source #
eventNever :: Event x a Source #
eventSwitch :: HasSpiderTimeline x => Switch x a -> Event x a Source #
eventCoincidence :: HasSpiderTimeline x => Coincidence x a -> Event x a Source #
subscribeCoincidenceInner :: HasSpiderTimeline x => Event x a -> Height -> CoincidenceSubscribed x a -> EventM x (Maybe a, Height, EventSubscribed x) Source #
newSubscriberHold :: (HasSpiderTimeline x, Patch p) => Hold x p -> IO (Subscriber x p) Source #
newSubscriberFan :: forall x k v. (HasSpiderTimeline x, GCompare k) => FanSubscribed x k v -> IO (Subscriber x (DMap k v)) Source #
newSubscriberSwitch :: forall x a. HasSpiderTimeline x => SwitchSubscribed x a -> IO (Subscriber x a) Source #
newSubscriberCoincidenceOuter :: forall x b. HasSpiderTimeline x => CoincidenceSubscribed x b -> IO (Subscriber x (Event x b)) Source #
newSubscriberCoincidenceInner :: forall x a. HasSpiderTimeline x => CoincidenceSubscribed x a -> IO (Subscriber x a) Source #
invalidateSubscriberHeight :: Height -> Subscriber x a -> IO () Source #
recalculateSubscriberHeight :: Height -> Subscriber x a -> IO () Source #
propagate :: forall x a. HasSpiderTimeline x => a -> WeakBag (Subscriber x a) -> EventM x () Source #
Propagate everything at the current height
propagateFast :: forall x a. HasSpiderTimeline x => a -> FastWeakBag (Subscriber x a) -> EventM x () Source #
Propagate everything at the current height
eventSubscribedRoot :: RootSubscribed x a -> EventSubscribed x Source #
eventSubscribedFan :: FanSubscribed x k v -> EventSubscribed x Source #
eventSubscribedSwitch :: SwitchSubscribed x a -> EventSubscribed x Source #
subscribeHoldEvent :: Hold x p -> Subscriber x p -> EventM x (EventSubscription x, Maybe p) Source #
behaviorHold :: Hold x p -> Behavior x (PatchTarget p) Source #
behaviorConst :: a -> Behavior x a Source #
behaviorPull :: Pull x a -> Behavior x a Source #
behaviorDyn :: Patch p => Dyn x p -> Behavior x (PatchTarget p) Source #
readHoldTracked :: Hold x p -> BehaviorM x (PatchTarget p) Source #
readBehaviorUntracked :: Defer (SomeHoldInit x) m => Behavior x a -> m a Source #
dynamicHold :: Hold x p -> DynamicS x p Source #
dynamicConst :: PatchTarget p -> DynamicS x p Source #
dynamicDyn :: (HasSpiderTimeline x, Patch p) => Dyn x p -> DynamicS x p Source #
dynamicDynIdentity :: HasSpiderTimeline x => Dyn x (Identity a) -> DynamicS x (Identity a) Source #
asksEventEnv :: forall x a. HasSpiderTimeline x => (EventEnv x -> a) -> EventM x a Source #
putCurrentHeight :: HasSpiderTimeline x => Height -> EventM x () Source #
hold :: (Patch p, Defer (SomeHoldInit x) m) => PatchTarget p -> Event x p -> m (Hold x p) Source #
getHoldEventSubscription :: forall p x. (HasSpiderTimeline x, Patch p) => Hold x p -> EventM x (EventSubscription x) Source #
heightBagSize :: HeightBag -> Int Source #
heightBagFromList :: [Height] -> HeightBag Source #
heightBagMax :: HeightBag -> Height Source #
heightBagVerify :: HeightBag -> HeightBag Source #
newInvalidatorSwitch :: SwitchSubscribed x a -> IO (Invalidator x) Source #
newInvalidatorPull :: Pull x a -> IO (Invalidator x) Source #
newMapDyn :: HasSpiderTimeline x => (a -> b) -> DynamicS x (Identity a) -> DynamicS x (Identity b) Source #
zipDynWith :: HasSpiderTimeline x => (a -> b -> c) -> DynamicS x (Identity a) -> DynamicS x (Identity b) -> DynamicS x (Identity c) Source #
buildDynamic :: (Defer (SomeDynInit x) m, Patch p) => EventM x (PatchTarget p) -> Event x p -> m (Dyn x p) Source #
unsafeBuildDynamic :: BehaviorM x (PatchTarget p) -> Event x p -> Dyn x p Source #
coincidence :: HasSpiderTimeline x => Event x (Event x a) -> Event x a Source #
run :: forall x b. HasSpiderTimeline x => [DSum (RootTrigger x) Identity] -> ResultM x b -> SpiderHost x b Source #
scheduleMerge' :: HasSpiderTimeline x => Height -> IORef Height -> EventM x () -> EventM x () Source #
debugFinalize :: Bool Source #
withIncreasedDepth :: proxy x -> m a -> m a Source #
tracePropagate :: CanTrace x m => proxy x -> String -> m () Source #
traceInvalidate :: String -> IO () Source #
traceInvalidateHeight :: String -> IO () Source #
debugSubscriber :: String -> Subscriber x a -> IO (Subscriber x a) Source #
debugSubscriber' :: String -> Subscriber x a -> Subscriber x a Source #
listsToForest :: Eq a => [[a]] -> Forest a Source #
showStacks :: [[String]] -> String Source #
propagateSubscriberHold :: forall x p. (HasSpiderTimeline x, Patch p) => Hold x p -> p -> EventM x () Source #
runBehaviorM :: BehaviorM x a -> Maybe (Weak (Invalidator x), IORef [SomeBehaviorSubscribed x]) -> IORef [SomeHoldInit x] -> IO a Source #
askInvalidator :: BehaviorM x (Maybe (Weak (Invalidator x))) Source #
askParentsRef :: BehaviorM x (Maybe (IORef [SomeBehaviorSubscribed x])) Source #
askBehaviorHoldInits :: BehaviorM x (IORef [SomeHoldInit x]) Source #
getDynHold :: (Defer (SomeHoldInit x) m, Patch p) => Dyn x p -> m (Hold x p) Source #
getRootSubscribed :: forall k x a. (GCompare k, HasSpiderTimeline x) => k a -> Root x k -> Subscriber x a -> IO (WeakBagTicket, RootSubscribed x a, Maybe a) Source #
cleanupRootSubscribed :: RootSubscribed x a -> IO () Source #
subscribeRootSubscribed :: RootSubscribed x a -> Subscriber x a -> IO WeakBagTicket Source #
fanInt :: HasSpiderTimeline x => Event x (IntMap a) -> EventSelectorInt x a Source #
fanIntSubscribed :: FastWeakBagTicket k -> FanInt x a -> IO (EventSubscribed x) Source #
getFanSubscribed :: (HasSpiderTimeline x, GCompare k) => k a -> Fan x k v -> Subscriber x (v a) -> EventM x (WeakBagTicket, FanSubscribed x k v, Maybe (v a)) Source #
cleanupFanSubscribed :: GCompare k => (k a, FanSubscribed x k v) -> IO () Source #
subscribeFanSubscribed :: GCompare k => k a -> FanSubscribed x k v -> Subscriber x (v a) -> IO WeakBagTicket Source #
getSwitchSubscribed :: HasSpiderTimeline x => Switch x a -> Subscriber x a -> EventM x (WeakBagTicket, SwitchSubscribed x a, Maybe a) Source #
cleanupSwitchSubscribed :: SwitchSubscribed x a -> IO () Source #
subscribeSwitchSubscribed :: SwitchSubscribed x a -> Subscriber x a -> IO WeakBagTicket Source #
getCoincidenceSubscribed :: forall x a. HasSpiderTimeline x => Coincidence x a -> Subscriber x a -> EventM x (WeakBagTicket, CoincidenceSubscribed x a, Maybe a) Source #
cleanupCoincidenceSubscribed :: CoincidenceSubscribed x a -> IO () Source #
subscribeCoincidenceSubscribed :: CoincidenceSubscribed x a -> Subscriber x a -> IO WeakBagTicket Source #
mergeG :: forall k q x v. (HasSpiderTimeline x, GCompare k) => (forall a. q a -> Event x (v a)) -> DynamicS x (PatchDMap k q) -> Event x (DMap k v) Source #
mergeWithMove :: forall k v q x. (HasSpiderTimeline x, GCompare k) => (forall a. q a -> Event x (v a)) -> DynamicS x (PatchDMapWithMove k q) -> Event x (DMap k v) Source #
mergeCheap :: forall k x q v. (HasSpiderTimeline x, GCompare k) => (forall a. q a -> Event x (v a)) -> DynamicS x (PatchDMap k q) -> Event x (DMap k v) Source #
mergeCheapWithMove :: forall k x v q. (HasSpiderTimeline x, GCompare k) => (forall a. q a -> Event x (v a)) -> DynamicS x (PatchDMapWithMove k q) -> Event x (DMap k v) Source #
invalidateMergeHeight :: Merge x k v s -> IO () Source #
invalidateMergeHeight' :: IORef Height -> Subscriber x a -> IO () Source #
revalidateMergeHeight :: Merge x k v s -> IO () Source #
scheduleMergeSelf :: HasSpiderTimeline x => Merge x k v s -> Height -> EventM x () Source #
checkCycle :: HasSpiderTimeline x => EventSubscribed x -> EventM x () Source #
mergeSubscriber :: forall x k v s a. (HasSpiderTimeline x, GCompare k) => EventSubscribed x -> Merge x k v s -> EventM x (k a) -> Subscriber x (v a) Source #
updateMerge :: (HasSpiderTimeline x, GCompare k) => EventSubscribed x -> Merge x k v s -> MergeUpdateFunc k v x p s -> p -> SomeMergeUpdate x Source #
mergeGCheap' :: forall k v x p s q. (HasSpiderTimeline x, GCompare k, PatchTarget p ~ DMap k q) => MergeGetSubscription x s -> MergeInitFunc k v q x s -> MergeUpdateFunc k v x p s -> MergeDestroyFunc k s -> DynamicS x p -> Event x (DMap k v) Source #
mergeInt :: forall x a. HasSpiderTimeline x => DynamicS x (PatchIntMap (Event x a)) -> Event x (IntMap a) Source #
mergeIntCheap :: forall x a. HasSpiderTimeline x => DynamicS x (PatchIntMap (Event x a)) -> Event x (IntMap a) Source #
fanG :: (HasSpiderTimeline x, GCompare k) => Event x (DMap k v) -> EventSelectorG x k v Source #
runHoldInits :: HasSpiderTimeline x => IORef [SomeHoldInit x] -> IORef [SomeDynInit x] -> IORef [SomeMergeInit x] -> EventM x () Source #
initHold :: HasSpiderTimeline x => SomeHoldInit x -> EventM x () Source #
initDyn :: HasSpiderTimeline x => SomeDynInit x -> EventM x () Source #
newEventEnv :: IO (EventEnv x) Source #
clearEventEnv :: EventEnv x -> IO () Source #
runFrame :: forall x a. HasSpiderTimeline x => EventM x a -> SpiderHost x a Source #
Run an event action outside of a frame
zeroHeight :: Height Source #
succHeight :: Height -> Height Source #
invalidateCoincidenceHeight :: CoincidenceSubscribed x a -> IO () Source #
updateSwitchHeight :: Height -> SwitchSubscribed x a -> IO () Source #
recalculateCoincidenceHeight :: CoincidenceSubscribed x a -> IO () Source #
calculateSwitchHeight :: SwitchSubscribed x a -> IO Height Source #
invalidate :: IORef [SomeSwitchSubscribed x] -> WeakList (Invalidator x) -> IO (WeakList (Invalidator x)) Source #
newJoinDyn :: HasSpiderTimeline x => DynamicS x (Identity (DynamicS x (Identity a))) -> Dyn x (Identity a) Source #
mapDynamicSpider :: HasSpiderTimeline x => (a -> b) -> Dynamic (SpiderTimeline x) a -> Dynamic (SpiderTimeline x) b Source #
holdSpiderEventM :: HasSpiderTimeline x => a -> Event (SpiderTimeline x) a -> EventM x (Behavior (SpiderTimeline x) a) Source #
holdDynSpiderEventM :: HasSpiderTimeline x => a -> Event (SpiderTimeline x) a -> EventM x (Dynamic (SpiderTimeline x) a) Source #
holdIncrementalSpiderEventM :: (HasSpiderTimeline x, Patch p) => PatchTarget p -> Event (SpiderTimeline x) p -> EventM x (Incremental (SpiderTimeline x) p) Source #
buildDynamicSpiderEventM :: HasSpiderTimeline x => SpiderPushM x a -> Event (SpiderTimeline x) a -> EventM x (Dynamic (SpiderTimeline x) a) Source #
unsafeNewSpiderTimelineEnv :: forall x. IO (SpiderTimelineEnv x) Source #
newSpiderTimeline :: IO (Some SpiderTimelineEnv) Source #
Create a new SpiderTimelineEnv
localSpiderTimeline :: proxy s -> SpiderTimelineEnv x -> SpiderTimelineEnv (LocalSpiderTimeline x s) Source #
withSpiderTimeline :: (forall x. HasSpiderTimeline x => SpiderTimelineEnv x -> IO r) -> IO r Source #
Pass a new timeline to the given function.
runSpiderHost :: SpiderHost Global a -> IO a Source #
Run an action affecting the global Spider timeline; this will be guarded by a mutex for that timeline
runSpiderHostForTimeline :: SpiderHost x a -> SpiderTimelineEnv x -> IO a Source #
Run an action affecting a given Spider timeline; this will be guarded by a mutex for that timeline
newEventWithTriggerIO :: forall x a. HasSpiderTimeline x => (RootTrigger x a -> IO (IO ())) -> IO (Event x a) Source #
newFanEventWithTriggerIO :: (HasSpiderTimeline x, GCompare k) => (forall a. k a -> RootTrigger x a -> IO (IO ())) -> IO (EventSelector x k) Source #