Class objectClass = null;
try{
if (dataClassName != null){
if (PrivilegedAccessHelper.shouldUsePrivilegedAccess()){
try {
dataClass = (Class)AccessController.doPrivileged(new PrivilegedClassForName(dataClassName, true, classLoader));
} catch (PrivilegedActionException exception) {
throw ValidationException.classNotFoundWhileConvertingClassNames(dataClassName, exception.getException());
}
} else {
dataClass = oracle.toplink.essentials.internal.security.PrivilegedAccessHelper.getClassForName(dataClassName, true, classLoader);
}
setDataClass(dataClass);
}
} catch (ClassNotFoundException exc){
throw ValidationException.classNotFoundWhileConvertingClassNames(dataClassName, exc);
}
try {
if (objectClassName != null){
if (PrivilegedAccessHelper.shouldUsePrivilegedAccess()){
try {
objectClass = (Class)AccessController.doPrivileged(new PrivilegedClassForName(objectClassName, true, classLoader));
} catch (PrivilegedActionException exception) {
throw ValidationException.classNotFoundWhileConvertingClassNames(objectClassName, exception.getException());
}
} else {
objectClass = oracle.toplink.essentials.internal.security.PrivilegedAccessHelper.getClassForName(objectClassName, true, classLoader);