public void processAnnotations() {
processPropertyAnnotations();
}
private void processPropertyAnnotations() {
DependentPlanningVariable dependentPlanningVariableAnnotation = variablePropertyDescriptor.getReadMethod()
.getAnnotation(DependentPlanningVariable.class);
String masterPropertyName = dependentPlanningVariableAnnotation.master();
masterPlanningVariableDescriptor = planningEntityDescriptor.getPlanningVariableDescriptor(masterPropertyName);
if (masterPlanningVariableDescriptor == null) {
throw new IllegalStateException("The planningEntityClass ("
+ planningEntityDescriptor.getPlanningEntityClass()
+ ") has a DependentPlanningVariable annotated property (" + variablePropertyDescriptor.getName()
+ ") that refers to a masterPropertyName (" + masterPropertyName
+ ") that does not exist on that class (" + planningEntityDescriptor.getPlanningEntityClass()
+ ").");
}
masterPlanningVariableDescriptor.addDependentPlanningVariableDescriptor(this);
String mappedByPropertyName = dependentPlanningVariableAnnotation.mappedBy();
if (!mappedByPropertyName.equals("")) {
Class<?> oppositeClass = variablePropertyDescriptor.getPropertyType();
PlanningEntityDescriptor oppositePlanningEntityDescriptor
= planningEntityDescriptor.getSolutionDescriptor().getPlanningEntityDescriptor(oppositeClass);
if (oppositePlanningEntityDescriptor == null) {