Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
en:rule:structured_diagram [2024-08-25 21:32] – [✘ How NOT to] Anatoly Belaychuk | en:rule:structured_diagram [2024-11-27 15:48] (current) – [✘ How NOT to] Anatoly Belaychuk | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ====== | + | ====== Follow structured modeling rules ====== |
- | {{tag> | + | {{tag> |
- | + | ||
- | {{en: | + | |
Leverage structured blocks and subprocesses. | Leverage structured blocks and subprocesses. | ||
Line 403: | Line 401: | ||
</ | </ | ||
- | Process will work fine (no hangouts) but it isn't obvious. | ||
- | |||
- | <bpmnio type=" | ||
- | <?xml version=" | ||
- | < | ||
- | <process id=" | ||
- | < | ||
- | < | ||
- | < | ||
- | </ | ||
- | <task id=" | ||
- | < | ||
- | < | ||
- | </ | ||
- | < | ||
- | <task id=" | ||
- | < | ||
- | < | ||
- | </ | ||
- | < | ||
- | < | ||
- | <task id=" | ||
- | < | ||
- | < | ||
- | </ | ||
- | < | ||
- | < | ||
- | < | ||
- | < | ||
- | < | ||
- | < | ||
- | < | ||
- | < | ||
- | </ | ||
- | < | ||
- | < | ||
- | < | ||
- | < | ||
- | </ | ||
- | </ | ||
- | < | ||
- | < | ||
- | < | ||
- | < | ||
- | </ | ||
- | < | ||
- | < | ||
- | </ | ||
- | < | ||
- | < | ||
- | </ | ||
- | < | ||
- | < | ||
- | </ | ||
- | < | ||
- | < | ||
- | </ | ||
- | < | ||
- | < | ||
- | </ | ||
- | < | ||
- | < | ||
- | < | ||
- | < | ||
- | </ | ||
- | < | ||
- | < | ||
- | < | ||
- | < | ||
- | </ | ||
- | < | ||
- | < | ||
- | < | ||
- | </ | ||
- | < | ||
- | < | ||
- | < | ||
- | </ | ||
- | < | ||
- | < | ||
- | < | ||
- | < | ||
- | </ | ||
- | < | ||
- | < | ||
- | < | ||
- | < | ||
- | </ | ||
- | < | ||
- | < | ||
- | < | ||
- | </ | ||
- | </ | ||
- | </ | ||
- | </ | ||
- | </ | ||
===== Notes ===== | ===== Notes ===== | ||
- | Фундаментом разработки программного обеспечения является | + | In software development, |
- | набор правил, благодаря которым облегчается понимание программного кода, сокращается число ошибок, | + | that make it easier to understand the program code, reduce the number of errors, simplify testing and subsequent modification. |
- | Структурное программирование запрещает произвольную передачу управления | + | Structured programming prohibits arbitrary transfer of control |
- | требуя компоновать программный код из структурных блоков | + | requiring the program code to be composed of structural blocks |
- | Кроме того, к принципам структурного программирования относится разработка сверху вниз и выделение повторяющихся фрагментов в подпрограммы | + | Structured programming also suggests top-down development with hierarchical decompositon into subroutines |
- | Модель бизнес-процесса тоже является своего рода | + | A business process model is also a kind of "program" |
- | Но проблемы читаемости, легкости тестирования и последующей модификации для моделей процессов даже более актуальны, | + | It existing in the form of a diagram, not the text of the program code. |
- | поскольку они должны быть понятны не только профессионалам | + | But the problems of readability, ease of testing and subsequent modification are even more pressing for process models, |
+ | since they must be understandable not only to professionals | ||
- | Поэтому принципы структурного программирования следует применять и к моделированию процессов, с учетом некоторых особенностей: | + | Therefore, the principles of structured programming should be applied to process modeling with certain adjustments: |
- | * набор структурных блоков здесь шире, см. [[#как надо]] | + | * the palette of structural blocks is wider, see [[#How to]] |
- | * аналогом | + | * the sequence flow (if not part of a structural block) is the equivalento of goto |
- | * как и в структурном программировании, блоки могут вкладываться друг в друга | + | * as in structured programming, blocks can be nested |
- | * как и в структурном программировании, моделировать процессы следует сверху вниз с использованием подпроцессов и вызовов повторно-используемых действий | + | * as in structured programming, processes should be modeled from top to bottom using subprocesses and call activities |
- | В отличие от программирования, принципы структурного моделирования - это рекомендация, | + | Unlike programming, the principles of structured modeling are rather recommendations than requirements. |
- | Бывают сценарии, когда от них можно отступить, если это позволяет адекватно отобразить сложную логику, | + | There are scenarios when it's reasonable to break them to display complex logic, make the process diagram more compact and understandable, see [[#Exceptions]]. |
- | Принципы структурного моделирования очерчивают для аналитика | + | The principles of structured modeling form a kind of "safe zone": |
- | в частности, у каждой расходящейся развилки есть парная к ней сходящаяся, | + | in particular, pair each diverging gateway with a convergin one and firmly nest blocks one into another |
- | Если приходится от этих принципах отступать, | + | As soon as you break these rules, you accept the the responsibility for the correctness and readability of the diagram. |
- | Такая гибкость является сильной стороной | + | Such flexibility is the strength of BPMN. |
- | Для сравнения, в нотации | + | In comparison, the BPEL notation imposes the principles of structured modeling rigidly, making it technically impossible to break. |
- | Например, если у расходящейся развилки нет парной сходящейся, | + | For example, if a diverging gateway isn't followed by a paired converging one then such a model will be syntactically incorrect. |
- | Из-за такой жесткости | + | Because of such rigidity, |
- | Оказалось, | + | It turned out that authors and users of graphical diagrams value the BPMN ability to connect arbitrary elements on the diagram with a sequence flow. |
- | Главное не злоупотреблять этой возможностью. | + | The point is not to overuse this ability. |
===== Exceptions ===== | ===== Exceptions ===== | ||