topgaren / DevStudy

0 stars 0 forks source link

PlantUML #6

Open topgaren opened 4 years ago

topgaren commented 4 years ago

PlantUML

What is PlantUML?

PlantUML 은 다이어그램을 빠르게 작성하기 위한 오픈 소스 프로젝트입니다.

PlantUML Manual : http://plantuml.com/ko/index

topgaren commented 4 years ago

Install PlantUML (Mac OS)

$ brew install plantuml
...
$ plantuml -version
PlantUML version 1.2019.08 (Sun Jul 14 04:25:14 KST 2019)
(GPL source distribution)
Java Runtime: Java(TM) SE Runtime Environment
JVM: Java HotSpot(TM) 64-Bit Server VM
Java Version: 1.8.0_191-b12
Operating System: Mac OS X
OS Version: 10.13.6
Default Encoding: UTF-8
Language: ko
Country: KR
Machine: Swiriui-MacBook-Pro.local
PLANTUML_LIMIT_SIZE: 4096
Processors: 8
Max Memory: 3,817,865,216
Total Memory: 257,425,408
Free Memory: 250,392,336
Used Memory: 7,033,072
Thread Active Count: 1

The environment variable GRAPHVIZ_DOT has been set to /usr/local/opt/graphviz/bin/dot
Dot executable is /usr/local/opt/graphviz/bin/dot
Dot version: dot - graphviz version 2.40.1 (20161225.0304)
Installation seems OK. File generation OK

How to use?

  1. *.txt 파일 작성 : [filename].txt
  2. *.png 파일 생성 : $ plantuml [filename].txt --> [filename].png

interface Observer {

class Subject {

class ObserverA {

class ObserverB {

Observer <|-- ObserverA Observer <|-- ObserverB Subject -right-o Observer

note bottom of Subject for observer in observers observer.update(); end note @enduml $ plantuml observer_pattern.txt


![observer_pattern](https://user-images.githubusercontent.com/45558487/63212819-cc3d0a00-c144-11e9-9aee-64f4feb2f1f9.png)