diff options
Diffstat (limited to 'docs/class-diag.puml')
-rw-r--r-- | docs/class-diag.puml | 28 |
1 files changed, 15 insertions, 13 deletions
diff --git a/docs/class-diag.puml b/docs/class-diag.puml index b8e8a63..3502aa5 100644 --- a/docs/class-diag.puml +++ b/docs/class-diag.puml @@ -26,14 +26,14 @@ exception Exception { rectangle Group_FileReading as "File reading" <<group>> { class FileReader <<Factory>> { - +open(url) : File& + +open(url) : FileStrategy& } - interface File { + interface FileStrategy { + read() : string + close() -- # open(string url) - # clone() : File* <<const>> + # clone() : FileStrategy* <<const>> } class LocalFile { - instance : LocalFile <<static>> @@ -46,11 +46,11 @@ rectangle Group_FileReading as "File reading" <<group>> { class Url <<irrelevant>> } - File <|.. LocalFile - File <|.. HTTPFile + FileStrategy <|.. LocalFile + FileStrategy <|.. HTTPFile - File <. FileReader - File .> FileReader + FileStrategy <. FileReader + FileStrategy .> FileReader HTTPFile --> CPR.Response CPR.Response - CPR.Url @@ -145,7 +145,9 @@ rectangle Group_Model as "Model" <<group>> { Color <.. TileAppearance } rectangle Group_Tile_Behavior as "Tile behavior" <<group>> { - interface TileBehavior + interface TileBehaviorStrategy + + class TileBehavior together { class GrayTileBehavior @@ -158,10 +160,10 @@ rectangle Group_Model as "Model" <<group>> { BlueTileBehavior -d[hidden]- YellowTileBehavior } - TileBehavior <|.. GrayTileBehavior - TileBehavior <|.. RedTileBehavior - TileBehavior <|.. BlueTileBehavior - TileBehavior <|.. YellowTileBehavior + TileBehaviorStrategy <|.. GrayTileBehavior + TileBehaviorStrategy <|.. RedTileBehavior + TileBehaviorStrategy <|.. BlueTileBehavior + TileBehaviorStrategy <|.. YellowTileBehavior Tile --> "state" TileBehavior } @@ -198,7 +200,7 @@ rectangle "Visualization" <<group>> { ' CanvasDeserializer <... Canvas ' Deserializer <... Museum -ParserStrategy ..> File +ParserStrategy ..> FileStrategy ' Museum .> Deserializer : friend Deserializer .> Museum |