mirror of
https://github.com/tiennm99/java-design-patterns.git
synced 2026-05-14 12:58:37 +00:00
5ba45701bf
* pattern:implemented the Template View pattern (#1320) * fix:added links in README and updated package name (#1320) --------- Co-authored-by: Ilkka Seppälä <iluwatar@users.noreply.github.com>
34 lines
668 B
Plaintext
34 lines
668 B
Plaintext
@startuml
|
|
package com.iluwater.templateview {
|
|
class App {
|
|
+ App()
|
|
+ main(args : String[]) {static}
|
|
}
|
|
|
|
abstract class TemplateView {
|
|
- LOGGER : Logger {static}
|
|
+ TemplateView()
|
|
+ render() : void {final}
|
|
# printHeader() : void
|
|
# renderDynamicContent() : void {abstract}
|
|
# printFooter() : void
|
|
}
|
|
|
|
class HomePageView {
|
|
- LOGGER : Logger {static}
|
|
+ HomePageView()
|
|
+ renderDynamicContent() : void
|
|
}
|
|
|
|
class ContactPageView {
|
|
- LOGGER : Logger {static}
|
|
+ ContactPageView()
|
|
+ renderDynamicContent() : void
|
|
}
|
|
}
|
|
|
|
App --> TemplateView
|
|
TemplateView <|-- HomePageView
|
|
TemplateView <|-- ContactPageView
|
|
@enduml
|