Hook: Define CountingStock Filter
Requirement
Only selected items of a CountingStock shall be visible to a part of
an application.
Filters are most often used in connection with displaying the
contents of CountingStocks. E.g., if you want the user to select
items from a Stock of available items, but want to keep a safety
margin, you can use a filtered CountingStock for the source Stock.
Method of AdaptationEnable Feature
Level of SupportParameter Pattern
HotSpotFilters
ParticipantsCountingStockFilter,
NewFilter
,
CountingStock,
originalCountingStock
,
filteredCountingStock
Changes
-
subclass NewFilter of CountingStockFilter.
-
NewFilter.countItems implements
CountingStockFilter.countItems
.
-
instance originalCountingStock of CountingStock.
-
instance filteredCountingStock of NewFilter with parameter
originalCountingStock.