/** @generated */ protected boolean canReorientTarget() { if (!(oldEnd instanceof Classifier && newEnd instanceof Classifier)) { return false; } return UMLBaseItemSemanticEditPolicy.getLinkConstraints() .canExistInformationItemRepresented_4020(getOldSource(), getNewTarget()); }
/** @generated */ protected boolean canReorientTarget() { if (!(oldEnd instanceof Element && newEnd instanceof Element)) { return false; } return UMLBaseItemSemanticEditPolicy.getLinkConstraints() .canExistCommentAnnotatedElement_4002(getOldSource(), getNewTarget()); }
/** @generated */ public boolean canExecute() { if (source == null && target == null) { return false; } if (source != null && false == source instanceof InformationItem) { return false; } if (target != null && false == target instanceof Classifier) { return false; } if (getSource() == null) { return true; // link creation is in progress; source is not defined yet } // target may be null here but it's possible to check constraint return UMLBaseItemSemanticEditPolicy.getLinkConstraints() .canCreateInformationItemRepresented_4020(getSource(), getTarget()); }