[keyword] Flag Plus

Graphical Unified Modeling Language (UML) diagrams for the contributed Webel module Flag Plus.

[uml] EntityFilter

Webel module:

UML element type:

OOE stereotypes:

A good example of how encapsulating related functions as static helper/builder class methods (that can be reverse engineered to UML) brings immediate advantage to both the code organisation and the UML diagramming, without even considering in detail yet how this might be handled as an object.

This helper/builder class can create both a non-AJAX and an AJAX-aware entity type filter form element, as well as offering some helper functions for the actual filtering against entity type.

[uml] flagplus.entitytype.inc

REFACTOR: this software engineering content is flagged as under consideration for refactoring.
HOT TIP: this content is flagged as highly recommended !

Webel module:

UML element type:

OOE stereotypes:

In migrating from the Drupal7 Island function-and-hook "flatland" to a more OOP and UML-friendly world we endeavour to create "bridge" include files that mediate between the classic Drupal7 hooks of the .module and the OO Class libraries, which progressively encapsulate as class attributes, class constants, and interface/class methods, the data and operations that were in old-style functions.

[uml] flagplus.flags.inc

REFACTOR: this software engineering content is flagged as under consideration for refactoring.
HOT TIP: this content is flagged as highly recommended !

Webel module:

UML element type:

OOE stereotypes:

There is an important IT moral to this story

Don't be discouraged if your UML overview diagrams are at first too complex, that is just your UML model telling you something very important, it is inviting you to refactor your system ! And the way to refactor it is to first identify such "scenarios" in separate diagrams. Later, these might become diagrams for dedicated Classes that correspond to a dedicated narrative.

[uml] BannerHelper

REFACTOR: this software engineering content is flagged as under consideration for refactoring.

Webel module:

UML element type:

OOE stereotypes:

extends [Generalization]: 

This is after some "divide-and-conquer" refactoring. It isolates some Flag Plus data, accessors, and some database methods related to the global Banner settings (stored as system variables), whereas per-Flag Banner settings (stored in a dedicated DB table) are now handled by BannerFlagHelper and IFlagBanner/ FlagBanner.

[uml] flagplus.banners.inc

REFACTOR: this software engineering content is flagged as under consideration for refactoring.

Webel module:

UML element type:

OOE stereotypes:

[uml] flagplus.admin.inc

STUB: this content is flagged as a placeholder only, with minimal content.

Webel module:

UML element type:

OOE stereotypes:

For admin forms and their handlers (and supporting functions). Currently there is only a stub admin welcome page.

For Flag Plus power admin of Flags visit flagplus.flags.inc.

For Flag Plus banners admin visit: flagplus.banners.inc.

[uml] AjaxHelper

Webel module:

UML element type:

OOE stereotypes:

[uml] flagplus.module

Webel module:

UML element type:

OOE stereotypes:

[uml] Common

STUB: this content is flagged as a placeholder only, with minimal content.

Webel module:

UML element type:

OOE stereotypes:

Constants common to the entire module.

Promotes robust Don't Repeat Yourself (DRY) code rather than error-prone Write Everything Twice (WET) code:

- Don't Repeat Yourself (DRY Principle)

- Write Everything Twice (WET) (because "we enjoy typing")

Any constant that is used in more than one file SHOULD be defined here (or should be similarly defined in another shared class) ! This makes it easier to adapt the entire module code to other modules.

[uml] Drupal\flagplus

Webel module:

UML element type:

OOE stereotypes:

Such package overview diagrams are useful for indicating the basic organisation of a module, but should not attempt to show too many Dependency, Usage, or Package/Element imports. Drill down into the dedicated "focus" class/implementation diagrams to see the detailed relationship of a focus element to its nearest neighbour related elements.

Pages

Subscribe to RSS - Flag Plus