public ExistingLibraryEditor getLibraryEditor(Library library){
    if (library instanceof LibraryEx) {
      final Library source = ((LibraryEx)library).getSource();
      if (source != null) {
        return getLibraryEditor(source);
      }
    }

    ExistingLibraryEditor libraryEditor = myLibrary2EditorMap.get(library);
    if (libraryEditor == null){
      libraryEditor = createLibraryEditor(library);
    }
    return libraryEditor;
  }
public ExistingLibraryEditor getLibraryEditor(Library library)