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.puml

249 lines
6.8 KiB
Plaintext

' C4-PlantUML
' https://github.com/adrianvlupu/C4-PlantUML
' Colors
' ##################################
!global $ELEMENT_FONT_COLOR = "#FFFFFF"
!global $LEGEND_FONT_COLOR = "#FFFFFF"
!global $LEGEND_TITLE_COLOR = "#000000"
' Styling
' ##################################
!global $TECHN_FONT_SIZE = 12
skinparam defaultTextAlignment center
skinparam wrapWidth 200
skinparam maxMessageSize 150
skinparam LegendBorderColor transparent
skinparam LegendBackgroundColor transparent
skinparam LegendFontColor $LEGEND_FONT_COLOR
skinparam rectangle {
StereotypeFontSize 12
shadowing false
}
skinparam database {
StereotypeFontSize 12
shadowing false
}
skinparam queue {
StereotypeFontSize 12
shadowing false
}
skinparam Arrow {
Color #666666
FontColor #666666
FontSize 12
}
skinparam rectangle<<boundary>> {
Shadowing false
StereotypeFontSize 0
FontColor #444444
BorderColor #444444
BorderStyle dashed
}
' Layout
' ##################################
!procedure HIDE_STEREOTYPE()
hide stereotype
!endprocedure
!procedure LAYOUT_AS_SKETCH()
skinparam backgroundColor #EEEBDC
skinparam handwritten true
skinparam defaultFontName "Comic Sans MS"
center footer <font color=red>Warning:</font> Created for discussion, needs to be validated
!endprocedure
!procedure LAYOUT_TOP_DOWN()
top to bottom direction
!endprocedure
!procedure LAYOUT_LEFT_RIGHT()
left to right direction
!endprocedure
' Boundaries
' ##################################
!unquoted function Boundary($alias, $label)
!return 'rectangle "=='+$label+'" <<boundary>> as '+$alias
!endfunction
!unquoted function Boundary($alias, $label, $type)
!return 'rectangle "=='+$label+'\n<size:'+$TECHN_FONT_SIZE+'>['+$type+']</size>" <<boundary>> as '+$alias
!endfunction
' Relationship
' ##################################
!unquoted procedure Rel_($alias1, $alias2, $label, $direction="")
$alias1 $direction $alias2 : **$label**
!endprocedure
!unquoted procedure Rel_($alias1, $alias2, $label, $techn, $direction="")
$alias1 $direction $alias2 : **$label**\n//<size:$TECHN_FONT_SIZE>[$techn]</size>//
!endprocedure
!unquoted procedure Rel($from, $to, $label)
Rel_($from, $to, $label, "-->>")
!endprocedure
!unquoted procedure Rel($from, $to, $label, $techn)
Rel_($from, $to, $label, $techn, "-->>")
!endprocedure
!unquoted procedure BiRel($from, $to, $label)
Rel_($from, $to, $label, "<<-->>")
!endprocedure
!unquoted procedure BiRel($from, $to, $label, $techn)
Rel_($from, $to, $label, $techn, "<<-->>")
!endprocedure
!unquoted procedure Rel_Back($from, $to, $label)
Rel_($from, $to, $label, "<<--")
!endprocedure
!unquoted procedure Rel_Back($from, $to, $label, $techn)
Rel_($from, $to, $label, $techn, "<<--")
!endprocedure
!unquoted procedure Rel_Neighbor($from, $to, $label)
Rel_($from, $to, $label, "->>")
!endprocedure
!unquoted procedure Rel_Neighbor($from, $to, $label, $techn)
Rel_($from, $to, $label, $techn, "->>")
!endprocedure
!unquoted procedure Rel_Back_Neighbor($from, $to, $label)
Rel_($from, $to, $label, "<<-")
!endprocedure
!unquoted procedure Rel_Back_Neighbor($from, $to, $label, $techn)
Rel_($from, $to, $label, $techn, "<<-")
!endprocedure
!unquoted procedure Rel_D($from, $to, $label)
Rel_($from, $to, $label, "-DOWN->>")
!endprocedure
!unquoted procedure Rel_D($from, $to, $label, $techn)
Rel_($from, $to, $label, $techn, "-DOWN->>")
!endprocedure
!unquoted procedure Rel_Down($from, $to, $label)
Rel_($from, $to, $label, "-DOWN->>")
!endprocedure
!unquoted procedure Rel_Down($from, $to, $label, $techn)
Rel_($from, $to, $label, $techn, "-DOWN->>")
!endprocedure
!unquoted procedure BiRel_D($from, $to, $label)
Rel_($from, $to, $label, "<<-DOWN->>")
!endprocedure
!unquoted procedure BiRel_D($from, $to, $label, $techn)
Rel_($from, $to, $label, $techn, "<<-DOWN->>")
!endprocedure
!unquoted procedure BiRel_Down($from, $to, $label)
Rel_($from, $to, $label, "<<-DOWN->>")
!endprocedure
!unquoted procedure BiRel_Down($from, $to, $label, $techn)
Rel_($from, $to, $label, $techn, "<<-DOWN->>")
!endprocedure
!unquoted procedure Rel_U($from, $to, $label)
Rel_($from, $to, $label, "-UP->>")
!endprocedure
!unquoted procedure Rel_U($from, $to, $label, $techn)
Rel_($from, $to, $label, $techn, "-UP->>")
!endprocedure
!unquoted procedure Rel_Up($from, $to, $label)
Rel_($from, $to, $label, "-UP->>")
!endprocedure
!unquoted procedure Rel_Up($from, $to, $label, $techn)
Rel_($from, $to, $label, $techn, "-UP->>")
!endprocedure
!unquoted procedure BiRel_U($from, $to, $label)
Rel_($from, $to, $label, "<<-UP->>")
!endprocedure
!unquoted procedure BiRel_U($from, $to, $label, $techn)
Rel_($from, $to, $label, $techn, "<<-UP->>")
!endprocedure
!unquoted procedure BiRel_Up($from, $to, $label)
Rel_($from, $to, $label, "<<-UP->>")
!endprocedure
!unquoted procedure BiRel_Up($from, $to, $label, $techn)
Rel_($from, $to, $label, $techn, "<<-UP->>")
!endprocedure
!unquoted procedure Rel_L($from, $to, $label)
Rel_($from, $to, $label, "-LEFT->>")
!endprocedure
!unquoted procedure Rel_L($from, $to, $label, $techn)
Rel_($from, $to, $label, $techn, "-LEFT->>")
!endprocedure
!unquoted procedure Rel_Left($from, $to, $label)
Rel_($from, $to, $label, "-LEFT->>")
!endprocedure
!unquoted procedure Rel_Left($from, $to, $label, $techn)
Rel_($from, $to, $label, $techn, "-LEFT->>")
!endprocedure
!unquoted procedure BiRel_L($from, $to, $label)
Rel_($from, $to, $label, "<<-LEFT->>")
!endprocedure
!unquoted procedure BiRel_L($from, $to, $label, $techn)
Rel_($from, $to, $label, $techn, "<<-LEFT->>")
!endprocedure
!unquoted procedure BiRel_Left($from, $to, $label)
Rel_($from, $to, $label, "<<-LEFT->>")
!endprocedure
!unquoted procedure BiRel_Left($from, $to, $label, $techn)
Rel_($from, $to, $label, $techn, "<<-LEFT->>")
!endprocedure
!unquoted procedure Rel_R($from, $to, $label)
Rel_($from, $to, $label, "-RIGHT->>")
!endprocedure
!unquoted procedure Rel_R($from, $to, $label, $techn)
Rel_($from, $to, $label, $techn, "-RIGHT->>")
!endprocedure
!unquoted procedure Rel_Right($from, $to, $label)
Rel_($from, $to, $label, "-RIGHT->>")
!endprocedure
!unquoted procedure Rel_Right($from, $to, $label, $techn)
Rel_($from, $to, $label, $techn, "-RIGHT->>")
!endprocedure
!unquoted procedure BiRel_R($from, $to, $label)
Rel_($from, $to, $label, "<<-RIGHT->>")
!endprocedure
!unquoted procedure BiRel_R($from, $to, $label, $techn)
Rel_($from, $to, $label, $techn, "<<-RIGHT->>")
!endprocedure
!unquoted procedure BiRel_Right($from, $to, $label)
Rel_($from, $to, $label, "<<-RIGHT->>")
!endprocedure
!unquoted procedure BiRel_Right($from, $to, $label, $techn)
Rel_($from, $to, $label, $techn, "<<-RIGHT->>")
!endprocedure
' Layout Helpers
' ##################################
!unquoted procedure Lay_D($from, $to)
$from -[hidden]D- $to
!endprocedure
!unquoted procedure Lay_U($from, $to)
$from -[hidden]U- $to
!endprocedure
!unquoted procedure Lay_R($from, $to)
$from -[hidden]R- $to
!endprocedure
!unquoted procedure Lay_L($from, $to)
$from -[hidden]L- $to
!endprocedure