Safe Haskell | None |
---|
Documentation
Typeable1 DBRef | |
Eq (DBRef a) | |
Eq (DBRef a) => Ord (DBRef a) | |
(IResource a, Typeable a) => Read (DBRef a) | |
Show (DBRef a) | |
SetOperations [DBRef a] [DBRef a] [DBRef a] | |
SetOperations [DBRef a] (JoinData a a') (JoinData a a') | |
Queriable reg a => RelationOps (reg -> a) a [DBRef reg] | |
(Typeable reg, IResource reg) => Select (reg -> a) (STM [DBRef reg]) (STM [a]) | |
(Typeable reg, IResource reg, Typeable reg', IResource reg', Select (reg -> a) (STM [DBRef reg]) (STM [a]), Select (reg' -> b) (STM [DBRef reg']) (STM [b])) => Select (reg -> a, reg' -> b) (STM (JoinData reg reg')) (STM [([a], [b])]) | |
(Typeable reg, IResource reg, Select (reg -> a) (STM [DBRef reg]) (STM [a]), Select (reg -> b) (STM [DBRef reg]) (STM [b])) => Select (reg -> a, reg -> b) (STM [DBRef reg]) (STM [(a, b)]) | |
SetOperations (JoinData a a') [DBRef a'] (JoinData a a') | |
SetOperations (JoinData a a') [DBRef a] (JoinData a a') | |
(Queriable reg a, Queriable reg' a) => RelationOps (reg -> a) (reg' -> a) (JoinData reg reg') | |
(Typeable reg, IResource reg, Select (reg -> a) (STM [DBRef reg]) (STM [a]), Select (reg -> b) (STM [DBRef reg]) (STM [b]), Select (reg -> c) (STM [DBRef reg]) (STM [c])) => Select (reg -> a, reg -> b, reg -> c) (STM [DBRef reg]) (STM [(a, b, c)]) | |
(Typeable reg, IResource reg, Select (reg -> a) (STM [DBRef reg]) (STM [a]), Select (reg -> b) (STM [DBRef reg]) (STM [b]), Select (reg -> c) (STM [DBRef reg]) (STM [c]), Select (reg -> d) (STM [DBRef reg]) (STM [d])) => Select (reg -> a, reg -> b, reg -> c, reg -> d) (STM [DBRef reg]) (STM [(a, b, c, d)]) |
addTrigger :: (IResource a, Typeable a) => (DBRef a -> Maybe a -> STM ()) -> IO ()Source
Add an user defined trigger to the list of triggers
Trriggers are called just before an object of the given type is created, modified or deleted.
The DBRef to the object and the new value is passed to the trigger.
The called trigger function has two parameters: the DBRef being accesed
(which still contains the old value), and the new value.
If the DBRef is being deleted, the second parameter is Nothing
.
if the DBRef contains Nothing, then the object is being created