// property is not specified - nothing to do.
return false;
}
// originalServerPlatform is always non-null - Session's constructor sets serverPlatform to NoServerPlatform
ServerPlatform originalServerPlatform = session.getServerPlatform();
String originalServerPlatformClassName = originalServerPlatform.getClass().getName();
if(originalServerPlatformClassName.equals(serverPlatformClassName)) {
// nothing to do - use the same value as before
return false;
}
// the new serverPlatform
ServerPlatform serverPlatform = null;
// New platform - create the new instance and set it.
Class cls = findClassForProperty(serverPlatformClassName, TopLinkProperties.TARGET_SERVER, loader);
try {
Constructor constructor = cls.getConstructor(new Class[]{oracle.toplink.essentials.internal.sessions.DatabaseSessionImpl.class});
serverPlatform = (ServerPlatform)constructor.newInstance(new Object[]{session});