All tutorials I can find always tackle with toy uml use cases like the one here http://www.ibm.com/developerworks/java/library/j-jmod0508/
I can’t see how you can model this in UML Use Case:
a customer can be either a Physical Person or a Company and that a Company has employees that are themselves physical persons. Company has also some persons who work for them as contractors who are physical persons but are not customers.
Could someone has any good idea and writes this model in yuml use cases http://yuml.me/ for example ?
Nobody seems to know UML Use Case so let’s say even Class Diagram or even Java or C# Class Diagram or even database design 🙂
Problem I see in the model below is that Person is a Customer and so all employees would also be customers which is wrong:

The following class diagram fulfills your needs:
You are actually working with two domains: the first domain is the hierarchy of the company: a company has employees and contractors which are persons; the second domain is the domain of customers, which can be companies and customers. So in this diagram you have a
Personwhich can be aContractor, anEmployeeor aCustomerPerson, which can also be aCustomer, and you have aCustomerCompanywhich is both aCustomerand aCompany.Note that I created
CustomerCompanywhich inherits fromCompanyinstead of makingCompanyinherit fromCustomersince I assume not all companies are customers.I used inheritance for all relations, but if multiple inheritance is not wanted, this can be done using interface.
The yuml code for this diagram is: