Menu

GeneratedDesign

Walter Lyrer

Design of generated Strategy/State code

The Strategy/State Generator provides a structure designed to be extendable for expected future changes. There is a factory interface and implementation:

  • I{BusinessName}StrategyFactory
  • {BusinessName}StrategyFactoryImpl

The strategies themselves have an interface, an abstract class and all required strategy classes.

  • I{BusinessName}Strategy
  • Abstract{BusinessName}Strategy
    • {BusinessName}{Condition[1]}Strategy
    • ...
    • {BusinessName}{Condition[n]}Strategy

Note, the abstract strategy can be omitted when setting field disableAbstraction to true in class GeneratorIn.

Note, too, that the business name can be omitted in the concrete strategy/state implementations by setting field disableConditionNameInClassName to true in class GeneratorIn.

Copyright

Copyright by Walter Lyrer

Disclaimer

The author cannot be made responsible for any damage caused by the Strategy/State Generator.
The usage of the Strategy/State Generator is on own risk.
The code is designed and implemented on best know-how and with good intentions by the author.
Especially is to mention that the generated code of the Strategy/State Generator is not guaranteed to run instantly correct.
Manual supervision is necessary.

Author

Walter Lyrer

Other projects from same author

Jacoge Java Generator Eclipse Plugin
Converter Generator
Visitor Generator
Named Parameter Converter

Project Members: