Module Spicey.ControllerGeneration

Summary of exported operations:

enauthModName :: String  Deterministic 
defCtrlModName :: String  Deterministic 
generateControllersForEntity :: String -> [Entity] -> Entity -> [Relationship] -> CurryProg  Deterministic 
mainController :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl  Deterministic 
newEntityType :: String -> Entity -> [Relationship] -> [Entity] -> CTypeDecl  Deterministic 
Generates a type alias for a "new entity" tuple type which is used to create and insert new entities (without an entity key).
newController :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl  Deterministic 
newForm :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl  Deterministic 
Generates the form definition to create a new entity.
newStore :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl  Deterministic 
Generates the store for WUI to create a new entity.
newTupleType :: Entity -> [Relationship] -> [Entity] -> CTypeExpr  Deterministic 
Computes the tuple type of the data to be stored and manipulated by the WUI to create a new entity.
createTransaction :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl  Deterministic 
Generates a transaction to store a new entity.
editController :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl  Deterministic 
Generates a controller to edit an entity.
editForm :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl  Deterministic 
Generates the form definition to edit an entity.
editStore :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl  Deterministic 
Generates the store for WUI to edit an entity.
editTupleType :: String -> Entity -> [Relationship] -> [Entity] -> CTypeExpr  Deterministic 
Computes the tuple type of the data to be stored and manipulated by the WUI to edit a new entity.
updateTransaction :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl  Deterministic 
Generates the transaction to update an entity.
deleteController :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl  Deterministic 
Generates controller to delete an entity after confirmation.
destroyController :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl  Deterministic 
Generates controller to delete an entity.
deleteTransaction :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl  Deterministic 
Generates a transaction to delete an entity.
listController :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl  Deterministic 
showController :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl  Deterministic 
manyToManyAddOrRemove :: String -> Entity -> [(String,String)] -> [Entity] -> [CFuncDecl]  Deterministic 
getAll :: String -> Entity -> [String] -> [Entity] -> [CFuncDecl]  Deterministic 
manyToOneGetRelated :: String -> Entity -> [String] -> [Entity] -> [Relationship] -> [CFuncDecl]  Deterministic 
relationshipName :: String -> String -> [Relationship] -> (String,String)  Deterministic 
displayErrorFunction :: (String,String)  Deterministic 
entityConstructorFunction :: String -> Entity -> [Relationship] -> (String,String)  Deterministic 
controllerFunction :: String -> String -> String -> Int -> CTypeExpr -> [CRule] -> CFuncDecl  Deterministic 
getReferencedEntityName :: Domain -> String  Deterministic 
relatedEntityNames :: Entity -> [Relationship] -> [String]  Deterministic 
relationshipsForEntity :: Entity -> [Relationship] -> [Relationship]  Deterministic 
newSuffix :: String -> [Attribute] -> [Relationship] -> String  Deterministic 
isGeneratedR :: Relationship -> Bool  Deterministic 
relatedRelation :: String -> Relationship -> String  Deterministic 
relationshipsForEntityName :: String -> [Relationship] -> [Relationship]  Deterministic 
getUserSessionInfoFunc :: CExpr  Deterministic 
checkAuthorizationFunc :: (String,String)  Deterministic 

Exported datatypes:


ControllerGenerator

Type synonym: ControllerGenerator = String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl


Exported operations:

enauthModName :: String  Deterministic 

Further infos:
  • solution complete, i.e., able to compute all solutions

defCtrlModName :: String  Deterministic 

Further infos:
  • solution complete, i.e., able to compute all solutions

mainController :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl  Deterministic 

newEntityType :: String -> Entity -> [Relationship] -> [Entity] -> CTypeDecl  Deterministic 

Generates a type alias for a "new entity" tuple type which is used to create and insert new entities (without an entity key).

newController :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl  Deterministic 

newForm :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl  Deterministic 

Generates the form definition to create a new entity.

newStore :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl  Deterministic 

Generates the store for WUI to create a new entity.

newTupleType :: Entity -> [Relationship] -> [Entity] -> CTypeExpr  Deterministic 

Computes the tuple type of the data to be stored and manipulated by the WUI to create a new entity.

createTransaction :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl  Deterministic 

Generates a transaction to store a new entity.

editController :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl  Deterministic 

Generates a controller to edit an entity.

editForm :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl  Deterministic 

Generates the form definition to edit an entity.

editStore :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl  Deterministic 

Generates the store for WUI to edit an entity.

editTupleType :: String -> Entity -> [Relationship] -> [Entity] -> CTypeExpr  Deterministic 

Computes the tuple type of the data to be stored and manipulated by the WUI to edit a new entity.

updateTransaction :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl  Deterministic 

Generates the transaction to update an entity.

deleteController :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl  Deterministic 

Generates controller to delete an entity after confirmation.

destroyController :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl  Deterministic 

Generates controller to delete an entity.

deleteTransaction :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl  Deterministic 

Generates a transaction to delete an entity.

listController :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl  Deterministic 

showController :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl  Deterministic 

manyToManyAddOrRemove :: String -> Entity -> [(String,String)] -> [Entity] -> [CFuncDecl]  Deterministic 

getAll :: String -> Entity -> [String] -> [Entity] -> [CFuncDecl]  Deterministic 

manyToOneGetRelated :: String -> Entity -> [String] -> [Entity] -> [Relationship] -> [CFuncDecl]  Deterministic 

relationshipName :: String -> String -> [Relationship] -> (String,String)  Deterministic 

displayErrorFunction :: (String,String)  Deterministic 

Further infos:
  • solution complete, i.e., able to compute all solutions

entityConstructorFunction :: String -> Entity -> [Relationship] -> (String,String)  Deterministic 

controllerFunction :: String -> String -> String -> Int -> CTypeExpr -> [CRule] -> CFuncDecl  Deterministic 

getReferencedEntityName :: Domain -> String  Deterministic 

relatedEntityNames :: Entity -> [Relationship] -> [String]  Deterministic 

newSuffix :: String -> [Attribute] -> [Relationship] -> String  Deterministic 

isGeneratedR :: Relationship -> Bool  Deterministic 

relatedRelation :: String -> Relationship -> String  Deterministic 

checkAuthorizationFunc :: (String,String)  Deterministic 

Further infos:
  • solution complete, i.e., able to compute all solutions