if (adviceElement != null) {
adviceElement.setExtraInfo(extra);
}
String targetHandle = targetNode.getHandleIdentifier();
if (advice.getKind().equals(AdviceKind.Softener)) {
IRelationship foreward = mapper.get(adviceHandle, IRelationship.Kind.DECLARE_SOFT, SOFTENS, runtimeTest, true);
if (foreward != null) {
foreward.addTarget(targetHandle);
}
IRelationship back = mapper.get(targetHandle, IRelationship.Kind.DECLARE, SOFTENED_BY, runtimeTest, true);
if (back != null) {
back.addTarget(adviceHandle);
}
} else {
IRelationship foreward = mapper.get(adviceHandle, IRelationship.Kind.ADVICE, ADVISES, runtimeTest, true);
if (foreward != null) {
foreward.addTarget(targetHandle);
}
IRelationship back = mapper.get(targetHandle, IRelationship.Kind.ADVICE, ADVISED_BY, runtimeTest, true);
if (back != null) {
back.addTarget(adviceHandle);
}
}
if (adviceElement.getSourceLocation() != null) {
model.addAspectInEffectThisBuild(adviceElement.getSourceLocation().getSourceFile());
}