mirror of
https://github.com/khibino/haskell-relational-record.git
synced 2025-01-07 13:46:41 +03:00
Add document.
This commit is contained in:
parent
d92fc81b1f
commit
64381c8142
@ -61,11 +61,15 @@ defineHasPrimaryKeyInstance :: TypeQ -> Int -> Q [Dec]
|
|||||||
defineHasPrimaryKeyInstance =
|
defineHasPrimaryKeyInstance =
|
||||||
defineHasKeyConstraintInstance [t| Primary |]
|
defineHasKeyConstraintInstance [t| Primary |]
|
||||||
|
|
||||||
defineHasPrimaryKeyInstanceDefault :: String -> Int -> Q [Dec]
|
defineHasPrimaryKeyInstanceDefault :: String -- ^ Table name
|
||||||
|
-> Int -- ^ Primary key index
|
||||||
|
-> Q [Dec] -- ^ Declaration of primary key constraint
|
||||||
defineHasPrimaryKeyInstanceDefault =
|
defineHasPrimaryKeyInstanceDefault =
|
||||||
defineHasPrimaryKeyInstance . recordTypeDefault
|
defineHasPrimaryKeyInstance . recordTypeDefault
|
||||||
|
|
||||||
defineHasNotNullKeyInstanceDefault :: String -> Int -> Q [Dec]
|
defineHasNotNullKeyInstanceDefault :: String -- ^ Table name
|
||||||
|
-> Int -- ^ Not null key index
|
||||||
|
-> Q [Dec] -- ^ Declaration of not null key constraint
|
||||||
defineHasNotNullKeyInstanceDefault =
|
defineHasNotNullKeyInstanceDefault =
|
||||||
defineHasNotNullKeyInstance . recordTypeDefault
|
defineHasNotNullKeyInstance . recordTypeDefault
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user