Module Spicey.ControllerGeneration

Summary of exported operations:

enauthModName :: String   
defCtrlModName :: String   
generateControllersForEntity :: String -> [Entity] -> Entity -> [Relationship] -> CurryProg   
mainController :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl   
newEntityType :: String -> Entity -> [Relationship] -> [Entity] -> CTypeDecl   
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   
newForm :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl   
Generates the form definition to create a new entity.
newStore :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl   
Generates the store for WUI to create a new entity.
newTupleType :: Entity -> [Relationship] -> [Entity] -> CTypeExpr   
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   
Generates a transaction to store a new entity.
editController :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl   
Generates a controller to edit an entity.
editForm :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl   
Generates the form definition to edit an entity.
editStore :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl   
Generates the store for WUI to edit an entity.
editTupleType :: String -> Entity -> [Relationship] -> [Entity] -> CTypeExpr   
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   
Generates the transaction to update an entity.
deleteController :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl   
Generates controller to delete an entity after confirmation.
destroyController :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl   
Generates controller to delete an entity.
deleteTransaction :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl   
Generates a transaction to delete an entity.
listController :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl   
showController :: String -> Entity -> [Relationship] -> [Entity] -> CFuncDecl   
manyToManyAddOrRemove :: String -> Entity -> [String] -> [Entity] -> [CFuncDecl]   
getAll :: String -> Entity -> [String] -> [Entity] -> [CFuncDecl]   
manyToManyGetRelated :: String -> Entity -> [String] -> [Entity] -> [CFuncDecl]   
manyToOneGetRelated :: String -> Entity -> [String] -> [Entity] -> [Relationship] -> [CFuncDecl]   
relationshipName :: String -> String -> [Relationship] -> (String,String)   
displayErrorFunction :: (String,String)   
entityConstructorFunction :: String -> Entity -> [Relationship] -> (String,String)   
controllerFunction :: String -> String -> String -> Int -> CTypeExpr -> [CRule] -> CFuncDecl   
getReferencedEntityName :: Domain -> String   
relatedEntityNames :: Entity -> [Relationship] -> [String]   
relationshipsForEntity :: Entity -> [Relationship] -> [Relationship]   
newSuffix :: String -> [Attribute] -> [Relationship] -> String   
isGeneratedR :: Relationship -> Bool   
relatedRelation :: String -> Relationship -> String   
relationshipsForEntityName :: String -> [Relationship] -> [Relationship]   
getUserSessionInfoFunc :: CExpr   
checkAuthorizationFunc :: (String,String)   

Exported datatypes:


ControllerGenerator

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


Exported operations:

enauthModName :: String   

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

defCtrlModName :: String   

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

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

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

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   

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

Generates the form definition to create a new entity.

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

Generates the store for WUI to create a new entity.

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

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   

Generates a transaction to store a new entity.

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

Generates a controller to edit an entity.

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

Generates the form definition to edit an entity.

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

Generates the store for WUI to edit an entity.

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

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   

Generates the transaction to update an entity.

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

Generates controller to delete an entity after confirmation.

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

Generates controller to delete an entity.

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

Generates a transaction to delete an entity.

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

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

manyToManyAddOrRemove :: String -> Entity -> [String] -> [Entity] -> [CFuncDecl]   

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

manyToManyGetRelated :: String -> Entity -> [String] -> [Entity] -> [CFuncDecl]   

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

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

Further infos:
  • partially defined

displayErrorFunction :: (String,String)   

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

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

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

getReferencedEntityName :: Domain -> String   

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

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

isGeneratedR :: Relationship -> Bool   

relatedRelation :: String -> Relationship -> String   

Further infos:
  • partially defined

checkAuthorizationFunc :: (String,String)   

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