if (object instanceof TreeItem) {
TreeItem item = (TreeItem) object;
return mapType(item.getData());
}
if (object instanceof ActivityPart) {
ActivityPart part = (ActivityPart) object;
Activity model = part.getModelElement();
return mapType(model.getInput());
}
if (object instanceof TransitionPart) {
TransitionPart part = (TransitionPart) object;
Transition trans = (Transition) part.getModel();
return mapType(trans.getInput());
}
return super.mapType(object);
}