mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
deprecate getAdditionalProjectLibrarySourceRoots; rename newFixedLibrary to newImmutableLibrary (IDEA-CR-17846)
This commit is contained in:
@@ -160,7 +160,7 @@ public class DirectoryIndexTest extends IdeaTestCase {
|
||||
@Override
|
||||
public Collection<SyntheticLibrary> getAdditionalProjectLibraries(@NotNull Project project) {
|
||||
return myProject == project ? Collections.singletonList(
|
||||
SyntheticLibrary.newFixedLibrary(null, Collections.singletonList(myLibAdditionalSrcDir))
|
||||
SyntheticLibrary.newImmutableLibrary(null, Collections.singletonList(myLibAdditionalSrcDir))
|
||||
) : Collections.emptyList();
|
||||
}
|
||||
}, getTestRootDisposable());
|
||||
|
||||
+4
-1
@@ -53,9 +53,12 @@ public abstract class AdditionalLibraryRootsProvider {
|
||||
if (roots.isEmpty()) {
|
||||
return Collections.emptyList();
|
||||
}
|
||||
return Collections.singletonList(SyntheticLibrary.newFixedLibrary(null, roots));
|
||||
return Collections.singletonList(SyntheticLibrary.newImmutableLibrary(null, roots));
|
||||
}
|
||||
|
||||
/**
|
||||
* @deprecated use {@link #getAdditionalProjectLibraries(Project)} instead
|
||||
*/
|
||||
@SuppressWarnings("DeprecatedIsStillUsed")
|
||||
@NotNull
|
||||
public Collection<VirtualFile> getAdditionalProjectLibrarySourceRoots(@NotNull Project project) {
|
||||
|
||||
@@ -53,7 +53,7 @@ public abstract class SyntheticLibrary {
|
||||
public abstract Collection<VirtualFile> getSourceRoots();
|
||||
|
||||
@NotNull
|
||||
public static SyntheticLibrary newFixedLibrary(@Nullable String name, @NotNull Collection<VirtualFile> sourceRoots) {
|
||||
public static SyntheticLibrary newImmutableLibrary(@Nullable String name, @NotNull Collection<VirtualFile> sourceRoots) {
|
||||
return new SyntheticLibrary() {
|
||||
@Nullable
|
||||
@Override
|
||||
|
||||
Reference in New Issue
Block a user