class ExternalInitializer {

    public <T> T loadExternalClass(final String externalClassName, final String classPath, final Class<T> interfaceToCast) {
        T result;
        try {
            result = externalClassInitializer.loadExternalClass(externalClassName, classPath, interfaceToCast);
        } catch (DescriptorValidationFailedException dvfe) {
            logger.info("Couldn't initialize external class: '{}'", dvfe.getMessage());
            String jarFolderPath = stubResourcePathProvider.getJarPathAsString();
            result = externalJarClassInitializer.loadExternalClass(externalClassName, jarFolderPath, interfaceToCast);
        }

        return result;
    }

}