You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
C4-PlantUML/C4_Container.puml

70 lines
2.2 KiB
Plaintext

!include https://raw.githubusercontent.com/adrianvlupu/C4-PlantUML/latest/C4_Context.puml
' uncomment the following line and comment the first to use locally
' !include C4_Context.puml
' Scope: A single software system.
' Primary elements: Containers within the software system in scope.
' Supporting elements: People and software systems directly connected to the containers.
' Intended audience: Technical people inside and outside of the software development team; including software architects, developers and operations/support staff.
' Colors
' ##################################
!global $CONTAINER_BG_COLOR = "#438DD5"
' Styling
' ##################################
skinparam rectangle<<container>> {
StereotypeFontColor $ELEMENT_FONT_COLOR
FontColor $ELEMENT_FONT_COLOR
BackgroundColor $CONTAINER_BG_COLOR
BorderColor #3C7FC0
}
skinparam database<<container>> {
StereotypeFontColor $ELEMENT_FONT_COLOR
FontColor $ELEMENT_FONT_COLOR
BackgroundColor $CONTAINER_BG_COLOR
BorderColor #3C7FC0
}
' Layout
' ##################################
!function LAYOUT_WITH_LEGEND()
hide stereotype
legend right
|<color:$LEGEND_TITLE_COLOR>**Legend**</color> |
|<$PERSON_BG_COLOR> person |
|<$SYSTEM_BG_COLOR> system |
|<$CONTAINER_BG_COLOR> container |
|<$EXTERNAL_PERSON_BG_COLOR> external person |
|<$EXTERNAL_SYSTEM_BG_COLOR> external system |
endlegend
!endfunction
' Elements
' ##################################
!unquoted function Container($alias, $label, $techn)
rectangle "==$label\n//<size:$TECHN_FONT_SIZE>[$techn]</size>//" <<container>> as $alias
!endfunction
!unquoted function Container($alias, $label, $techn, $descr)
rectangle "==$label\n//<size:$TECHN_FONT_SIZE>[$techn]</size>//\n\n $descr" <<container>> as $alias
!endfunction
!unquoted function ContainerDb($alias, $label, $techn)
database "==$label\n//<size:$TECHN_FONT_SIZE>[$techn]</size>//" <<container>> as $alias
!endfunction
!unquoted function ContainerDb($alias, $label, $techn, $descr)
database "==$label\n//<size:$TECHN_FONT_SIZE>[$techn]</size>//\n\n $descr" <<container>> as $alias
!endfunction
' Boundaries
' ##################################
!unquoted function Container_Boundary($alias, $label)
!return Boundary($alias, $label, "Container")
!endfunction