setIndividualCandidacy(candidacy);
}
protected void attachAvailablePaymentCode(final Person person) {
YearMonthDay candidacyDate = getIndividualCandidacy().getCandidacyDate().toDateTimeAtStartOfDay().toYearMonthDay();
IndividualCandidacyPaymentCode paymentCode =
IndividualCandidacyPaymentCode.getAvailablePaymentCodeAndUse(getPaymentCodeType(), candidacyDate, this, person);
if (paymentCode == null) {
throw new DomainException("error.IndividualCandidacyEvent.invalid.payment.code");
}
}