Given the following code I have to draw the corresponding class diagram:
public class Shop
{
List<Client> clients;
Storage store;
User chief;
Set<Invoice> invoices;
}
public class Invoice
{
Map<Product, Row> rows;
Client client;
}
public class Client{}
public class Product{}
public class Storage
{
Map<Integer, Product> products;
}
public class Row
{
Product p;
double qty;
}
On draw.io I produced the following design:
Focus of my question is on - Relation between Invoice and row: Is it correct to draw the qualified association like so? On draw.io I found no option to depict this particular case. I built it by dragging Product class to be adjacent to Invoice.
Relation between Storage and Product. Is it correct? Or should I represent it also like a qualified association using class Integer as qualifier?
Do you see any error on relation arrows or cardinality?