You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Application-Web/Documentation/mvc/auth.puml

32 lines
1.1 KiB

@startuml
class AuthController {
+__construct (model : AuthModel)
+ displayRegister() : HttpResponse
+ register(request : array,session : MutableSessionHandle) : HttpResponse
+ displayLogin() : HttpResponse
+ login(request : array , session : MutableSessionHandle) : HttpResponse
}
AuthController *-- "- model" AuthModel
class AuthModel {
+ __construct(gateway : AccountGateway)
+ register(username:string, password:string, confirmPassword:string, email:string, &failures:array): ?Account + generateToken() : string
+ generateToken(): string
+ login(email:string, password:string, &failures:array): ?Account
}
AuthModel *-- "- gateway" AccountGateway
class AccountGateway{
+ __construct(con : Connexion)
+ insertAccount(name:string, email:string, token:string, hash:string, profilePicture:string): int
+ getRowsFromMail(email:string): ?array
+ getHash(email:string): ?string
+ exists(email:string): bool
+ getAccountFromMail(email:string): ?Account
+ getAccountFromToken(token:string): ?Account
}
AccountGateway *--"- con" Connexion
@enduml