mirror of
https://github.com/tiennm99/java-design-patterns.git
synced 2026-08-17 02:23:26 +00:00
docs: updates to several patterns
This commit is contained in:
+2
-4
@@ -43,7 +43,9 @@ public interface Threat {
|
||||
int id();
|
||||
ThreatType type();
|
||||
}
|
||||
```
|
||||
|
||||
```java
|
||||
public interface ThreatAwareSystem {
|
||||
String systemId();
|
||||
List<? extends Threat> threats();
|
||||
@@ -222,10 +224,6 @@ Running the example produces the following console output.
|
||||
08:33:23.581 [main] INFO com.iluwatar.filterer.App -- Filtered by probability = 0.99 : SimpleProbabilisticThreatAwareSystem(systemId=Sys-1, threats=[SimpleProbableThreat{probability=0.99} SimpleThreat(threatType=TROJAN, id=1, name=Trojan-ArcBomb)])
|
||||
```
|
||||
|
||||
## Class diagram
|
||||
|
||||

|
||||
|
||||
## Applicability
|
||||
|
||||
* Use when you need to filter a collection of objects dynamically based on different criteria.
|
||||
|
||||
Reference in New Issue
Block a user