code: private void cache(final Key key, final Collection<LookupResult> sources, final int stateId) {
          synchronized (this) {
              if (stateId == this.state.get()) {
                  this.lookupCache.put(key, sources);
              }
          }
      }
docs: A mapping might apply to any type somewhere within a resource's
  {@link  MappableTypeHierarchy}. This cache saves the registrar from searching
  this entire hierarchy each time the model is resolved by remembering a found
  resource type -&gt; model relationship.