private @NotNull List<String> getAllowedNamespaces(final XmlFile file) {
    CachedValue<Map<String, List<String>>> value = file.getUserData(NAMESPACE_PROVIDER_KEY);
    if (value == null) {
      file.putUserData(NAMESPACE_PROVIDER_KEY, value = CachedValuesManager.getManager(file.getProject()).createCachedValue(() -> {
        Map<String, List<String>> map = ConcurrentFactoryMap.createMap(key-> {
            final DomFileDescription<?> description = DomManager.getDomManager(file.getProject()).getDomFileDescription(file);
            if (description == null) return Collections.emptyList();
            return description.getAllowedNamespaces(key, file);
          }
        );
        return CachedValueProvider.Result.create(map, file);
      }, false));
    }

    final List<String> list = value.getValue().get(myNamespaceKey);
    assert list != null;
    return list;
  }
private @NotNull List<String> getAllowedNamespaces(final XmlFile file)