@Override
    public void loadPolicy(String policyImpl, IAsyncResultHandler<IPolicy> handler) {
        if (policyImpl == null) {
            handler.handle(AsyncResultImpl.<IPolicy>create(new PolicyNotFoundException(policyImpl)));
            return;
        }

        // Not synchronized - don't care if we create 2 or 3 of these, it's not worth
        // the synchronization overhead to protect against that.
        if (policyCache.containsKey(policyImpl)) {
            handler.handle(AsyncResultImpl.create(policyCache.get(policyImpl)));
            return;
        }

        // Handle the various policyImpl formats.  Valid formats include:
        //   class:fullyQualifiedClassname - the class is expected to be on the classpath
        if (policyImpl.startsWith("class:")) { //$NON-NLS-1$
            doLoadFromClasspath(policyImpl, handler);
        } else if (policyImpl.startsWith("plugin:")) { //$NON-NLS-1$
            doLoadFromPlugin(policyImpl, handler);
        } else {
            handler.handle(AsyncResultImpl.<IPolicy>create(new PolicyNotFoundException(policyImpl)));
        }
    }
@see io.apiman.gateway.engine.policy.IPolicyFactory#loadPolicy(java.lang.String, io.apiman.gateway.engine.async.IAsyncResultHandler)
gateway/engine/core/src/main/java/io/apiman/gateway/engine/policy/PolicyFactoryImpl.java