mirror of
https://github.com/st-tu-dresden-praktikum/swt23w23
synced 2024-06-23 21:23:43 +02:00
Simon Bruder
bac025fd0a
This finally makes the licensing under AGPL-3.0-or-later explicit after I got the okay from the kickstart source owners. This also checks the REUSE compliance in a pre commit hook, and therefore also in CI.
116 lines
3.7 KiB
Plaintext
116 lines
3.7 KiB
Plaintext
' SPDX-License-Identifier: AGPL-3.0-or-later
|
|
' SPDX-FileCopyrightText: 2023 swt23w23
|
|
@startuml
|
|
'maybe for sneidc since he did videoshop:cahnge-password'
|
|
skinparam linetype ortho
|
|
skinparam groupInheritance 2
|
|
|
|
package Salespoint {
|
|
interface UserAccountManagement
|
|
interface DataInitalizer
|
|
class UserAccount
|
|
class AbstractAggregateRoot
|
|
class Role
|
|
class Errors
|
|
}
|
|
|
|
package Spring {
|
|
class CrudRepository
|
|
class Streamable
|
|
class WebDataBinder
|
|
class Errors
|
|
interface Validator
|
|
}
|
|
|
|
package catering.users {
|
|
class User {
|
|
- address : String
|
|
- fullName : String
|
|
+ User(userAccount : UserAccount, address : String, fullName : String)
|
|
+ User()
|
|
+ getAddress() : String
|
|
+ setAddress(address:String) : String
|
|
+ getFullName() : String
|
|
+ setFullName(fullName:String) : String
|
|
+ getUsername() : String
|
|
+ setUsername(username:String) : boolean
|
|
+ getUserAccount() : UserAccount
|
|
+ getId() : UserIdentifier
|
|
+ isEnabled() : boolean
|
|
+ hasRole(role:String) : boolean
|
|
+ equals(obj:Object) : boolean
|
|
+ hashCode() : int
|
|
}
|
|
User ..> WebDataBinder
|
|
User --> UserAccount : "-userAccount"
|
|
User --|> AbstractAggregateRoot : <<extends>>
|
|
|
|
class UserController {
|
|
+ UserController(userManagement: UserManagement)
|
|
- initProfileBinder(binder : WebDataBinder) : void
|
|
- initRegistrationBinder(binder : WebDataBinder) : void
|
|
+ unauthorized() : String
|
|
+ register() : String
|
|
+ register(form:RegistrationForm,result:Errors) : String
|
|
+ loginPage() : String
|
|
+ viewProfile(model:Model,userAccount:UserAccount) : String
|
|
+ editProfile(userAccount:UserAccount,form:ProfileForm,result:Errors,model:Model) : String
|
|
+ disableUser(userAccount:UserAccount) : String
|
|
+ getCustomer(model:Model) : String
|
|
+ removeCustomer(user:User) : String
|
|
+ editCustomer(user:User,model:Model) : String
|
|
+ updateCustomer(user:User,username:String,address:String)
|
|
}
|
|
UserController --> UserManagement : "-userManagement"
|
|
UserController ..> User
|
|
UserController ..> UserAccount
|
|
UserController ..> Role
|
|
UserController ..> UserForm
|
|
UserController ..> FormValidator
|
|
UserController ..> WebDataBinder
|
|
|
|
class UserManagement {
|
|
+ UserManagement(users:UserRepository,userAccounts:UserAccountManagement)
|
|
+ createCustomer(name:String, password:String, address:String) : User
|
|
+ createAdmin(name:String, password:String, address:String,fullName:String) : User
|
|
+ save(user:User) : User
|
|
+ getUsers() : UserRepository
|
|
+ disableUserAccount(userAccount:UserAccount) : void
|
|
+ getUserByAccount(userAccount:UserAccount) : Optional<User>
|
|
}
|
|
UserManagement --> UserAccountManagement : "-userAccounts"
|
|
UserManagement --> UserRepository : "-users"
|
|
UserManagement ..> User
|
|
class UserDataInitalizer {
|
|
- userManagement : UserManagement
|
|
+ UserDataInitalizer(userManagement : UserManagement)
|
|
+ initalize() : void
|
|
}
|
|
UserDataInitalizer --> UserManagement : "-userManagement"
|
|
UserDataInitalizer ..|> DataInitalizer
|
|
class UserRepository {
|
|
+ findAll() : Streamable<User>
|
|
}
|
|
UserRepository --|> CrudRepository : <<extends>>
|
|
UserRepository ..|> Streamable
|
|
UserRepository o-- User
|
|
class UserForm {
|
|
- username: String
|
|
- password: String
|
|
- address: String
|
|
- password: String
|
|
+ UserForm(username:String,address:String,fullName:String,password:String)
|
|
+ getUsername() : String
|
|
+ getAddress() : String
|
|
+ getFullName() : String
|
|
+ getPassword() : String
|
|
}
|
|
class FormValidator {
|
|
supports(c:Class<?>) : boolean
|
|
validate(o:Object,e:Errors) : void
|
|
}
|
|
FormValidator ..> Validator
|
|
FormValidator --> Errors
|
|
}
|
|
@enduml
|