1

I'm modelling a Filter class that stores the options for filtering a search. Some of the attributes are multiple choice.

For example, if you are filtering hotel rooms you have a Price attribute that can take these three values: Best, Average, High. You can choose many values at the same time. In an UI would be represented as a group of checkboxes.

Can this be represented in a UML class diagram?

Robert Harvey
201k55 gold badges469 silver badges682 bronze badges
asked Dec 13, 2014 at 15:21
1
  • Actually, you have three boolean attributes: BestPrice, AveragePrice and HighPrice. Commented Dec 13, 2014 at 16:37

1 Answer 1

2

(1)

enter image description here

(2)

enter image description here

(3)

?

See also: uml-diagrams.org: Class and Object Diagrams Overview


As @robert-harvey pointed out, your requirement to select many values at the same time is strange as you can see from the model

answered Dec 13, 2014 at 16:38

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.