concept model in category security

appears as: model, A model, models, model, The model, models
Secure by Design

This is an excerpt from Manning's book Secure by Design.

Different things are represented in different ways in the domain, some explicit and some implicit. For example, the model contains order as a concept, and an order has a monetary value. An order also consists of order lines, each with a book and a quantity. A book has a title, an ISBN, and a price. Order, order line, and book are explicit concepts in the domain. Quantity, title, ISBN, and price are implicit concepts, represented by integers, strings, and so forth. Rephrased, a quantity is an integer without restrictions. Looking at it this way, it seems strange that order, order line, and book are all well elaborated, but quantity is left as an integer without consideration. How did it become this way?

A model is a simplified version of reality where you’ve removed irrelevant parts. For example, when you check in a bag at the airport, there’s no need for the system to represent your shoe size. On the other hand, it’s probably relevant to represent how heavy the bag is. To make it easier to understand and code the system, you create a model that contains the weight of the bag (but not the shoe size of the passenger), keeping just the details you think are relevant.

To be clear, models aren’t diagrams. In many other contexts, model means a specific diagram type, like an entity-relationship model often used for database design or the class diagram from UML. These diagrams are representations of the model, but the model itself is the conceptual understanding of how our simplified view of reality works.

A model is a simplification of reality, a simplification we still accept as a valid representation of the real thing.

We’ll now leave the realm of toys and take with us the idea that a model is a simplified understanding of the real thing. This goes for the models you use in system development as well. If you model a person, you might choose to grab onto a few attributes: a person has a name, is of a certain age, has a specific shoe size, and optionally has a pet. Agreed, this is a crude model, but a model nevertheless (figure 3.2).

Figure 3.2 One possible model of people and pets

figure03-02.eps

A model is a simplification, but it must still be general enough so that you can capture some variations that you think are interesting. In our example, we want to allow different names, different ages, and different shoe sizes, and we allow people to have pets or not. All these differences we allow to show up in the model. We don’t make any distinctions between people of different height or pay any attention to their hairdo (figure 3.3).

Figure 3.3 Joe, age 34, shoe size 9, and his dog Zarphac, together with Jane, age 28, shoe size 6, no pet

figure03-03.eps

You can represent this model in many different ways. You can use plain text to explain what you mean. You can use different kinds of diagrams to illustrate it (for example, compare figures 3.2 and 3.4). You can use code (pseudocode or actual code from a programming language). The important point here is that none of these representations is the model. Class diagrams in particular are often confused with being the model, but the model, as such, isn’t any of the representations. The model is the conceptual understanding of what you consider as essential in your modeling—in this case, name, age, shoe size, and pet.

Figure 3.4 The same model as before, but another representation

figure03-04.eps

The main benefit of keeping models as really simplified versions of reality is that simple models are easier to make strict. This is something that’s essential when you later build software from them.