if (getFeatureProvider().getBusinessObjectForPictogramElement(pictogramElement) == null) {
continue;
}
Object object = getFeatureProvider().getBusinessObjectForPictogramElement(pictogramElement);
if (object instanceof SequenceFlow) {
ContextMenuEntry subMenuDelete = new ContextMenuEntry(new DeleteSequenceFlowFeature(getFeatureProvider()), context);
subMenuDelete.setText("Delete sequence flow"); //$NON-NLS-1$
subMenuDelete.setSubmenu(false);
menuList.add(subMenuDelete);
} else if (object instanceof Association) {
final ContextMenuEntry subMenuDelete = new ContextMenuEntry(new DeleteAssociationFeature(getFeatureProvider()), context);