mirror of
https://github.com/st-tu-dresden-praktikum/swt23w23
synced 2024-07-19 21:04:36 +02:00
Improve developer documentation packaging proposals
This commit is contained in:
parent
1f9d756fa9
commit
95a2d9bab0
|
@ -12,7 +12,6 @@ package Salespoint {
|
||||||
interface DataInitializer
|
interface DataInitializer
|
||||||
interface Inventory << T > InventoryItem >>
|
interface Inventory << T > InventoryItem >>
|
||||||
class Product
|
class Product
|
||||||
' + has price,name and categories : Iterable'
|
|
||||||
class Quantity
|
class Quantity
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -22,6 +21,9 @@ package catering.catalog {
|
||||||
+ findByType(type, sort : Sort) : Iterable
|
+ findByType(type, sort : Sort) : Iterable
|
||||||
+ findByEventType(type) : Iterable
|
+ findByEventType(type) : Iterable
|
||||||
}
|
}
|
||||||
|
CateringCatalog --o CatalogController : "-catalog"
|
||||||
|
CateringCatalog ..> Catalog : "<bind> <T->Product"
|
||||||
|
|
||||||
class CatalogController {
|
class CatalogController {
|
||||||
+ CatalogController()
|
+ CatalogController()
|
||||||
+ eventcateringCatalog(model : Model) : String
|
+ eventcateringCatalog(model : Model) : String
|
||||||
|
@ -29,29 +31,21 @@ package catering.catalog {
|
||||||
+ mobilebreakfast(model : Model) : String
|
+ mobilebreakfast(model : Model) : String
|
||||||
+ rentacookCatalog(model : Model) : String
|
+ rentacookCatalog(model : Model) : String
|
||||||
}
|
}
|
||||||
|
CatalogController --> Inventory : "- inventory"
|
||||||
|
CatalogController ..> Model : "use"
|
||||||
|
|
||||||
class Consumable {
|
class Consumable {
|
||||||
wholesalePrice
|
wholesalePrice
|
||||||
retailPrice
|
retailPrice
|
||||||
promotionPrice [0..1]
|
promotionPrice [0..1]
|
||||||
}
|
}
|
||||||
|
Consumable --|> Product
|
||||||
|
|
||||||
class Rentable {
|
class Rentable {
|
||||||
pricePerHour
|
pricePerHour
|
||||||
}
|
}
|
||||||
|
Rentable --|> Product
|
||||||
}
|
}
|
||||||
|
|
||||||
CateringCatalog --o "-catalog" CatalogController
|
|
||||||
'- for listing entries to customers'
|
|
||||||
|
|
||||||
Inventory "- inventory" <-- CatalogController
|
|
||||||
'- for checking availabilty'
|
|
||||||
|
|
||||||
Model "use" <.. CatalogController
|
|
||||||
'- for generating html for a view'
|
|
||||||
|
|
||||||
|
|
||||||
Catalog <.. "<bind> <T->Product" CateringCatalog
|
|
||||||
|
|
||||||
Product <|-- Consumable
|
|
||||||
Product <|-- Rentable
|
|
||||||
|
|
||||||
@enduml
|
@enduml
|
BIN
src/main/asciidoc/models/design/catalog.svg
(Stored with Git LFS)
BIN
src/main/asciidoc/models/design/catalog.svg
(Stored with Git LFS)
Binary file not shown.
|
@ -25,22 +25,22 @@ package catering.inventory {
|
||||||
+ InventoryController(inventory : UniqueInventory)
|
+ InventoryController(inventory : UniqueInventory)
|
||||||
+ stock(model : Model) : String
|
+ stock(model : Model) : String
|
||||||
}
|
}
|
||||||
|
InventoryController ..> Model
|
||||||
|
InventoryController --> UniqueInventory : "-inventory"
|
||||||
|
|
||||||
class InventoryInitializer {
|
class InventoryInitializer {
|
||||||
+ InventoryInitializer(inventory : UniqueInventory, catalog : CateringCatalog)
|
+ InventoryInitializer(inventory : UniqueInventory, catalog : CateringCatalog)
|
||||||
+ initialize() : void
|
+ initialize() : void
|
||||||
}
|
}
|
||||||
|
InventoryInitializer --> CateringCatalog : "-cateringCatalog"
|
||||||
|
InventoryInitializer ..|> DataInitializer
|
||||||
|
InventoryInitializer ..> Quantity
|
||||||
|
InventoryInitializer ..> UniqueInventoryItem
|
||||||
|
InventoryInitializer ---> UniqueInventory : "-inventory"
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
CateringCatalog "1 -cateringCatalog" <-- InventoryInitializer
|
|
||||||
DataInitializer <|.. InventoryInitializer
|
|
||||||
Quantity <.. InventoryInitializer
|
|
||||||
UniqueInventoryItem <.. InventoryInitializer
|
|
||||||
UniqueInventory "1 -inventory" <-- InventoryInitializer
|
|
||||||
|
|
||||||
Model <.. InventoryController
|
|
||||||
UniqueInventory "1 -inventory" <-- InventoryController
|
|
||||||
|
|
||||||
|
|
||||||
@enduml
|
@enduml
|
BIN
src/main/asciidoc/models/design/inventory.svg
(Stored with Git LFS)
BIN
src/main/asciidoc/models/design/inventory.svg
(Stored with Git LFS)
Binary file not shown.
|
@ -10,17 +10,18 @@ package Spring {
|
||||||
}
|
}
|
||||||
|
|
||||||
package Salespoint {
|
package Salespoint {
|
||||||
|
interface OrderManager <<"T > Order">>
|
||||||
class Cart
|
class Cart
|
||||||
class Cash
|
class Cash
|
||||||
class Order
|
class Order
|
||||||
class Product
|
|
||||||
class Quantity
|
class Quantity
|
||||||
class UserAccount
|
class UserAccount
|
||||||
enum OrderStatus
|
enum OrderStatus
|
||||||
}
|
}
|
||||||
|
|
||||||
package catering.catalog {
|
package catering.catalog {
|
||||||
class Product
|
class Consumable
|
||||||
|
class Rentable
|
||||||
}
|
}
|
||||||
|
|
||||||
package catering.order {
|
package catering.order {
|
||||||
|
@ -31,6 +32,16 @@ package catering.order {
|
||||||
+ buy(cart : Cart, userAccount : UserAccount) : String
|
+ buy(cart : Cart, userAccount : UserAccount) : String
|
||||||
+ orders(model : Model) : String
|
+ orders(model : Model) : String
|
||||||
}
|
}
|
||||||
|
OrderController --> OrderManager : "-orderManager"
|
||||||
|
OrderController ..> Model
|
||||||
|
OrderController ..> UserAccount
|
||||||
|
OrderController ..> Order
|
||||||
|
OrderController ..> OrderStatus
|
||||||
|
OrderController ..> Cash
|
||||||
|
OrderController ..> Quantity
|
||||||
|
OrderController ..> Cart
|
||||||
|
OrderController ..> Consumable
|
||||||
|
OrderController ..> Rentable
|
||||||
}
|
}
|
||||||
|
|
||||||
@enduml
|
@enduml
|
BIN
src/main/asciidoc/models/design/order.svg
(Stored with Git LFS)
BIN
src/main/asciidoc/models/design/order.svg
(Stored with Git LFS)
Binary file not shown.
|
@ -4,37 +4,51 @@ skinparam linetype ortho
|
||||||
skinparam groupInheritance 2
|
skinparam groupInheritance 2
|
||||||
|
|
||||||
package Salespoint {
|
package Salespoint {
|
||||||
Class PersistentUserAccountManager
|
interface UserAccountManagement
|
||||||
Interface UserAccountRepository
|
interface DataInitalizer
|
||||||
Class UserAccount
|
class UserAccount
|
||||||
Class Role
|
UserAccount - Role : "0...*"
|
||||||
PersistentUserAccountManager "1" <-- UserAccountRepository
|
class Role
|
||||||
UserAccountRepository o-- UserAccount
|
|
||||||
UserAccount - "0...*" Role
|
|
||||||
}
|
}
|
||||||
|
|
||||||
package catering.users {
|
package catering.users {
|
||||||
'what is on the left will be higher up'
|
class Customer {
|
||||||
UserAccount <|-- AdministratorAccount
|
|
||||||
UserAccount <|-- CustomerAccount
|
|
||||||
class AdministratorAccount {
|
|
||||||
|
|
||||||
}
|
|
||||||
class CustomerAccount {
|
|
||||||
- address
|
- address
|
||||||
- email
|
- email
|
||||||
|
+ Customer(userAccount : UserAccount, address : String, email : String)
|
||||||
|
+ getAddress() : String
|
||||||
|
+ setAddress() : String
|
||||||
|
+ getUserAccount() : UserAccount
|
||||||
}
|
}
|
||||||
|
Customer --> UserAccount : "-userAccount"
|
||||||
|
|
||||||
Class UserController {
|
class UserController {
|
||||||
+ UserController()
|
+ UserController()
|
||||||
+ register(form : Form, model : Model) : String
|
+ register(form : Form, model : Model) : String
|
||||||
+ customers(model : Model) : String
|
+ customers(model : Model) : String
|
||||||
}
|
}
|
||||||
|
UserController --> CustomerManagement : "-customerManagement"
|
||||||
UserController --> "1" PersistentUserAccountManager
|
|
||||||
|
|
||||||
|
class CustomerManagement {
|
||||||
|
+ CustomerManagement(customers : CustomerRepository, userAccounts : UserAccountsManagement)
|
||||||
|
+ createCustomer(form : RegistrationForm) : Customer
|
||||||
|
+ findAll() : Streamable
|
||||||
|
}
|
||||||
|
CustomerManagement ---> UserAccountManagement : "-userAccounts"
|
||||||
|
CustomerManagement ...> Role : "uses"
|
||||||
|
class CustomerDataInitalizer {
|
||||||
|
+ CustomerDataInitalizer(userAcccountManager : UserAccountManagement, customerRepository : CustomerRepository)
|
||||||
|
+ initalize() : void
|
||||||
|
}
|
||||||
|
CustomerDataInitalizer --> CustomerManagement : "-customerManagement"
|
||||||
|
CustomerDataInitalizer --> UserAccountManagement : "-userAcccountManagement"
|
||||||
|
CustomerDataInitalizer ..|> DataInitalizer
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
'do employees need an account?'
|
'do employees need an account?'
|
||||||
|
|
||||||
@enduml
|
@enduml
|
BIN
src/main/asciidoc/models/design/user.svg
(Stored with Git LFS)
BIN
src/main/asciidoc/models/design/user.svg
(Stored with Git LFS)
Binary file not shown.
Loading…
Reference in a new issue