@NotNull
  private Map<String, String> getArchetypeDescriptor(MavenArchetype archetype) {
    if (myProjectOrNull == null) return Collections.emptyMap();
    Map<String, String> descriptor = MavenArchetypeManager.getInstance(myProjectOrNull)
      .resolveAndGetArchetypeDescriptor(archetype.groupId, archetype.artifactId, archetype.version, archetype.repository);
    return descriptor == null ? Collections.emptyMap() : descriptor;
  }
@NotNull
  private Map<String, String> getArchetypeDescriptor(MavenArchetype archetype)