Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- namespace org.acme.model
- //Utilisateur
- abstract participant User identified by idUser {
- o String idUser
- o String firstName
- o String lastName
- o String birthDate
- o Address address
- o String phone
- o String mail optional
- }
- //Docteur
- participant Doctor extends User{
- o Boolean isAllowedToPrescribe
- o Boolean isAllowedToVaccine
- }
- //Pharmacien
- participant Pharmacist extends User{
- o Boolean canDeliverVaccine
- --> Storage storage
- }
- //Compagnie de stockage des vaccins
- participant StorageCompany extends User{
- o String siretNumber
- --> Storage[] storages
- }
- //Patient
- participant Patient identified by id{
- o String id
- o String firstName
- o String lastName
- o String bloodGroup
- o String birthDate
- o Address address
- o String phone
- o VaccineType[] alreadyDone
- }
- //Storage = stock (CSV)
- asset Storage identified by idStorage{
- o String idStorage
- o String name
- o Address adress
- o String description
- --> Vaccine[] vaccines
- }
- //Vaccin
- asset Vaccine identified by idVaccine{
- o String idVaccine
- o VaccinState vaccinState
- o VaccineType vaccineType
- o Double price optional
- o Address location optional
- }
- //Prescription = ordonnance médicale
- asset Prescription identified by idPrescription{
- o String idPrescription
- o Boolean isValid default = true
- o VaccineType VaccineType
- --> Doctor doctor
- --> Patient patient
- }
- //OrderVacc = bon de commande pour un vaccin
- asset OrderVacc identified by idOrderVacc{
- o String idOrderVacc
- --> Pharmacist pharmacist
- --> StorageCompany storageCompany
- --> Vaccine vaccine
- }
- //Adresse
- concept Address {
- o Integer zipCode optional
- o String street optional
- o String city default ="Montpellier"
- o String country default = "FR"
- }
- //Type vaccin
- // asset VaccineType identified by idVaccineType{
- // o String idVaccineType
- // o String name
- // o String description
- // }
- asset VaccineType identified by name{
- o String name
- o String description
- }
- //Etat du vaccin (stocké, en déplacement, commandé)
- enum VaccinState {
- o STORED
- o DELIVERED
- o RESERVED
- }
- //Requirement = une ordonnance
- transaction Prescribe{
- o String idPrescription
- o VaccineType vaccineType
- --> Doctor doctor
- --> Patient patient
- }
- //Savoir si le stock du pharmacien contient un vaccin de ce type
- transaction DeliverVaccine{
- --> Patient patient
- --> Prescription prescription
- --> Pharmacist pharmacist
- }
- //Order = une commande
- transaction OrderVaccine{
- o VaccineType vaccineType
- o String idOrderVacc
- --> Pharmacist orderer
- --> StorageCompany storageCompany
- }
- //Transport
- transaction Transportation{
- --> Vaccine vaccine
- --> Pharmacist pharmacist
- o DateTime arrival
- }
- //Vaccination
- transaction Vaccination{
- --> Patient patient
- --> Doctor doctor
- --> Vaccine vaccine
- o String suivi // doit devenir un asset suivivaccin si on a le temps :d
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement