WhiteStarUML: 5.5.7.0 / Windows 8.1 (64bit)
Steps to reproduce this error:
- open an empty class diagramm
- Choose and apply with no changes GoF-Pattern: Composite
- Choose GoF-Pattern: Iterator
- Let Iterator-Pattern-Class "Aggregate" be the Composite-Pattern-Class "Component"
- Let Iterator-Pattern-Class "ConcreteAggregate" be the Composite-Pattern-Classes "Leaf" and "Composite"
- click on "apply"
Now I recieve a partial-german error message:
Pattern application failed (Error message: 'undefined' ist Null oder kein Objekt)
My English translation of this is:
Pattern application failed (Error message: 'undefined' is null or not an object)
I don't know: If this message want to give me as user a message for having done a user-error,
or is it a message for the application programmers, that is something wrong in WhiteStarUML.
In both cases I don't understand, what is going wrong.
I have the screenshot attached.
Best regards,
Robert Hartmann
It looks like a copy/paste glitch in the Iterator script. Find file:
\modules\staruml-pattern\pattern repository\GoF\Iterator\Iterator.js
and replace line 146:
var conIter_len = concreteAggregate.length - 1;
with:
var conIter_len = concreteIterator.length - 1;