Module
Test.Serialization.Symbiote.Core
- Package
- purescript-symbiote
- Repository
- athanclark/purescript-symbiote
#SymbioteOperation Source
class SymbioteOperation a o op | a -> op, op -> a, a -> o whereA type-level relation between a type and appropriate, testable operations on that type.
Members
perform :: op -> a -> o
#Operation Source
type Operation a s = sA synonym for s, because we can't quantify the type family and have to store it serialized, but trying to denote that it still "belongs" to a.
#Symbiote Source
class (SymbioteOperation a o op) <= Symbiote a o op s | a -> op, op -> a, a -> o whereA serialization format for a particular type, and serialized data type.
Members
#SymbioteProtocol Source
data SymbioteProtocol a sProtocol state for a particular topic
Constructors
MeGenerated { operation :: Operation a s, received :: s, value :: a }ThemGenerating { gen :: Maybe { operation :: s, value :: s } }NotStartedFinished
#SymbioteGeneration Source
newtype SymbioteGeneration a sProtocol generation state
Constructors
SymbioteGeneration { protocol :: SymbioteProtocol a s, size :: Int }
#newGeneration Source
newGeneration :: forall s a. SymbioteGeneration a s#SymbioteState Source
newtype SymbioteState a o sInternal existential state of a registered topic with type's facilities
Constructors
#ExistsSymbiote Source
data ExistsSymbiote :: Type -> Type#mkExistsSymbiote Source
mkExistsSymbiote :: forall s o a. SymbioteState a o s -> ExistsSymbiote s#runExistsSymbiote Source
runExistsSymbiote :: forall r s. (forall o a. SymbioteState a o s -> r) -> ExistsSymbiote s -> r#runSymbioteT Source
runSymbioteT :: forall m s. Monad m => SymbioteT s m Unit -> Boolean -> m (Map Topic (ExistsSymbiote s))#GenerateSymbiote Source
data GenerateSymbiote sConstructors
DoneGeneratingGeneratedSymbiote { generatedOperation :: s, generatedValue :: s }
#generateSymbiote Source
generateSymbiote :: forall m s. MonadEffect m => ExistsSymbiote s -> m (GenerateSymbiote s)#getProgress Source
getProgress :: forall m s. MonadEffect m => ExistsSymbiote s -> m Number