return true;
}
void verifyForActivation() {
if (RuleStatus.REMOVED == rule.getStatus()) {
throw new BadRequestException("Rule was removed: " + rule.getKey());
}
if (rule.isTemplate()) {
throw new BadRequestException("Rule template can't be activated on a Quality profile: " + rule.getKey());
}
if (rule.getKey().isManual()) {
throw new BadRequestException("Manual rule can't be activated on a Quality profile: " + rule.getKey());
}
if (!profile.getLanguage().equals(rule.getLanguage())) {
throw new BadRequestException(String.format("Rule %s and profile %s have different languages", rule.getKey(), profile.getKey()));
}
}