run an individual verifier test of a declated cmr field of the class
ComponentNameConstructor compName = getVerifierContext().getComponentNameConstructor();
if (rrd.getPartner().getIsMany()) {
// must be one the collection interface
if (rrd.getCMRFieldType()==null) {
addErrorDetails(result, compName);
result.addErrorDetails(smh.getLocalString
(getClass().getName() + ".failed2",
"Error : CMR field [ {0} ] cmr-field-type must be defined for one-to-many or many-to-many relationships and the value of the cmr-field-type element must be either: java.util.Collection or java.util.Set",
new Object[] {rrd.getCMRField()}));
return false;
} else {
CMRFieldInfo info = rrd.getCMRFieldInfo();
if (rrd.getCMRFieldType().equals(info.type.getName())) {
result.addGoodDetails(smh.getLocalString
(getClass().getName() + ".passed",
"CMR field [ {0} ] is the same type as declared in the deployment descriptors [ {1} ]",
new Object[] {info.name, info.role.getCMRFieldType()}));
return true;
} else {
addErrorDetails(result, compName);
result.addErrorDetails(smh.getLocalString
(getClass().getName() + ".failed",
"Error : CMR field [ {0} ] is not the same type as declared in the deployment descriptors [ {1} ]",
new Object[] {info.name, info.role.getCMRFieldType()}));
return false;
}
}
}
return true;