void (PsiFile file, VirtualFile assoc) { final VirtualFile virtualFile = file.getVirtualFile(); if (virtualFile == null) { LOG.warn("No VirtualFile for " + file.getName()); return; } VirtualFilePointerManager filePointerManager = VirtualFilePointerManager.getInstance(); for (VirtualFilePointer pointer : myAssociations.keySet()) { if (pointer.getUrl().equals(virtualFile.getUrl())) { VirtualFilePointerContainer container = myAssociations.get(pointer); if (container == null) { container = filePointerManager.createContainer(this); myAssociations.put(pointer, container); } if (container.findByUrl(assoc.getUrl()) == null) { container.add(assoc); touch(); } return; } } final VirtualFilePointerContainer container = filePointerManager.createContainer(this); container.add(assoc); myAssociations.put(filePointerManager.create(virtualFile, this, null), container); touch(); }