We are developing a system to track inventory in our regional offices.
At its core, the system will have a list of "assets" - things like bikes, computers, tents. Each property goes to states like "active", "lost", "check out", "inventorid". Some states have additional information such as "check out" or "inventorized by".
Therefore, I am thinking that each state will be a sub-class of a guardian class or implement the iState interface. This part is clear to me.
In what situation I am living, it is a good OOP design that a business argument has been given about which state can be followed in the previous state (asset object is called "last" situation Will keep in). For example, check-ins can only be checked out. Active must be the first state recorded on a property.
Any ideas or hints will be useful
And yes, I know that we should pay attention to COOTs, but the management has so far gone ahead with running their own equipment Have decided.
Answer your own question as you like. See patterns.
Comments
Post a Comment