From 7b26bf2bcc05b23de4a2221e2defeb5e4d92e755 Mon Sep 17 00:00:00 2001 From: Vladimir Krivosheev Date: Mon, 28 Sep 2020 19:23:15 +0200 Subject: [PATCH] refine icon-loading-stat flow (describe `svg-prebuilt`) GitOrigin-RevId: 8217d75f69907d41bd56dcfecb67a0c81e7f207f --- platform/docs/build.main.kts | 2 +- platform/docs/icon-loading-stat.puml | 17 +- platform/docs/out/getting-service.svg | 4 +- platform/docs/out/icon-loading-stat.svg | 282 ++++++++++-------- platform/docs/out/index.html | 50 ++++ .../docs/out/projectClose-dispose-flow.svg | 6 +- 6 files changed, 228 insertions(+), 133 deletions(-) create mode 100644 platform/docs/out/index.html diff --git a/platform/docs/build.main.kts b/platform/docs/build.main.kts index eb4af2a41a07..90e9d9061345 100644 --- a/platform/docs/build.main.kts +++ b/platform/docs/build.main.kts @@ -1,6 +1,6 @@ // Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file. @file:Repository("https://repo1.maven.org/maven2/") -@file:DependsOn("net.sourceforge.plantuml:plantuml:1.2020.15") +@file:DependsOn("net.sourceforge.plantuml:plantuml:1.2020.17") import net.sourceforge.plantuml.FileFormat import net.sourceforge.plantuml.FileFormatOption diff --git a/platform/docs/icon-loading-stat.puml b/platform/docs/icon-loading-stat.puml index b72f3c9f3d08..45ed13efb25d 100644 --- a/platform/docs/icon-loading-stat.puml +++ b/platform/docs/icon-loading-stat.puml @@ -1,8 +1,6 @@ @startuml !include jb-plantuml-theme.puml -' Time measurement: svg-decode includes svg-cache-read. - :find-icon; note right Externally called method ""IconLoader.findIcon"" @@ -24,11 +22,17 @@ if (Is Cached) then (yes) else (no) if (Is resourceClass Provided) then (yes) :load-from-resource] - if (Is Resource Exist) then (yes) - else (no) - ' That's why load-from-resource maybe not equal to sum of ""svg-load"" and ""png-load"" - :Return ""null""; + if (Is prebuiltCacheId Provided) then (yes) + :svg-prebuilt] + :Return Image; detach; + else + if (Is Resource Exist) then (yes) + else (no) + ' That's why load-from-resource maybe not equal to sum of ""svg-load"" and ""png-load"" + :Return ""null""; + detach; + endif endif else (no) :load-from-url] @@ -36,6 +40,7 @@ else (no) if (Is SVG) then (yes) :svg-cache-read] + if (Is Cached) then (yes) else (no) :svg-decode] diff --git a/platform/docs/out/getting-service.svg b/platform/docs/out/getting-service.svg index 60434b6cec30..01f83f7c5741 100644 --- a/platform/docs/out/getting-service.svg +++ b/platform/docs/out/getting-service.svg @@ -60,7 +60,7 @@ active disposed or dispose in progress - + synchronized on service class Is Initializing? @@ -71,7 +71,7 @@ PluginException Cyclic Service Initialization - + non cancelable diff --git a/platform/docs/out/icon-loading-stat.svg b/platform/docs/out/icon-loading-stat.svg index 6e37ee9fb69d..fb8a65505754 100644 --- a/platform/docs/out/icon-loading-stat.svg +++ b/platform/docs/out/icon-loading-stat.svg @@ -1,5 +1,6 @@ - + - + @@ -24,125 +29,158 @@ - - Load Image - - Is SVG - yes - no - - svg-load - - png-load - - - Is resourceClass Provided - yes - no - - load-from-resource - - Return - null - - no - Is Resource Exist - yes - - load-from-url - - - Is SVG - yes - no - - svg-cache-read - - svg-decode - - no - Is Cached - yes - - - png-decode - - - no - Is Cached - yes - - - Return Image - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + Externally called method + IconLoader.findIcon + + find-icon + + + Internally called method + CachedImageIcon.loadImage + . + Called numerous times per + CachedImageIcon + instance — to compute a new scale. + + find-icon-load + + Is SVG + yes + no + + svg-load + + png-load + + + Is resourceClass Provided + yes + no + + load-from-resource + + Is prebuiltCacheId Provided + yes + + svg-prebuilt + + Return Image + + Return + null + + no + Is Resource Exist + yes + + load-from-url + + + Is SVG + yes + no + + svg-cache-read + + svg-decode + + no + Is Cached + yes + + + png-decode + + + no + Is Cached + yes + + + Return Image + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/platform/docs/out/index.html b/platform/docs/out/index.html new file mode 100644 index 000000000000..cd97dc3f76e7 --- /dev/null +++ b/platform/docs/out/index.html @@ -0,0 +1,50 @@ + + + + + + IntelliJ Platform Activity Diagrams + + + + +
+
+ +
+ + +
+ + + + diff --git a/platform/docs/out/projectClose-dispose-flow.svg b/platform/docs/out/projectClose-dispose-flow.svg index 02032f98ce41..8ec70ba077d5 100644 --- a/platform/docs/out/projectClose-dispose-flow.svg +++ b/platform/docs/out/projectClose-dispose-flow.svg @@ -1,5 +1,7 @@ - +