for (final ClassOutline classOutline : outline.getClasses()) {
final ClassOutlineImpl cc = (ClassOutlineImpl) classOutline;
final JDefinedClass implClass = classOutline.implClass;
for (final FieldOutline fieldOutline : classOutline.getDeclaredFields()) {
JType type = TypeUtil.getCommonBaseType(codeModel, Util.listPossibleTypes(cc, fieldOutline.getPropertyInfo()));
if (((type.name().equals("BasicLink") || ((type.name().equals("Link")) && Util.upperFirst(fieldOutline.getPropertyInfo().getName(false)).equals("Icon"))))) {
/*
* special case for Icon. IconStyle uses protected BasicLink icon.
* subclasses.get(currentFieldName) will return, that
* possible subclasses for BasicLink are Icon and Link,
* hence createAndSetLink and createAndSetIcon methods
* are created. This isn't desired as IconStyle should
* define protected Icon icon.
*
* If it is possible to change the type of a variable
* at the CClassInfo-Level, this if block would be
* obsolete.
*/
type = classIcon.unboxify();
}
final String currentFieldName = Util.eliminateTypeSuffix(type.name());
// if (fieldOutline.getPropertyInfo().getName(false).equals("coordinates")) {
// LOG.info("+1 "+ cc.implRef.name() + " " + currentFieldName + " " + fieldOutline.getPropertyInfo().getName(false));
// }
if (currentFieldName.equals("AbstractObject")) {
// LOG.info("skip abstract object");