public static OASFactoryResolver instance() {
        if (instance == null) {
            synchronized (OASFactoryResolver.class) {
                if (instance != null) {
                    return instance;
                }

                ClassLoader cl = AccessController.doPrivileged(new PrivilegedAction<ClassLoader>() {
                    @Override
                    public ClassLoader run() {
                        return Thread.currentThread().getContextClassLoader();
                    }
                });
                if (cl == null) {
                    cl = OASFactoryResolver.class.getClassLoader();
                }

                OASFactoryResolver newInstance = loadSpi(cl);

                if (newInstance == null) {
                    throw new IllegalStateException("No OASFactoryResolver implementation found!");
                }

                instance = newInstance;
            }
        }

        return instance;
    }
public static OASFactoryResolver instance ( ) { if ( instance == null ) { synchronized ( OASFactoryResolver . class ) { if ( instance != null ) { return instance ; } ClassLoader cl = AccessController . doPrivileged ( new PrivilegedAction < ClassLoader > ( ) { @ Override public ClassLoader run ( ) { return Thread . currentThread ( ) . getContextClassLoader ( ) ; } } ) ; if ( cl == null ) { cl = OASFactoryResolver . class . getClassLoader ( ) ; } OASFactoryResolver newInstance = loadSpi ( cl ) ; if ( newInstance == null ) { throw new IllegalStateException ( "No OASFactoryResolver implementation found!" ) ; } instance = newInstance ; } } return instance ; }
Creates an OASFactoryResolver object.
Only used internally from within {@link org.eclipse.microprofile.openapi.OASFactory}

@return an instance of OASFactoryResolver