mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
[jps] cleanup: remove implementations of deprecated JpsElement.BulkModificationSupport.applyChanges
The method isn't used anymore. GitOrigin-RevId: 1783d1d74ecc1f3c46d738c14ce89bdbaaa0cc43
This commit is contained in:
committed by
intellij-monorepo-bot
parent
436ed15d10
commit
82d7fcff34
@@ -30,11 +30,6 @@ final class JpsJLinkProperties extends JpsElementBase<JpsJLinkProperties> {
|
||||
return new JpsJLinkProperties(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsJLinkProperties modified) {
|
||||
copyToThis(modified);
|
||||
}
|
||||
|
||||
private void copyToThis(@NotNull JpsJLinkProperties copy) {
|
||||
compressionLevel = copy.compressionLevel;
|
||||
verbose = copy.verbose;
|
||||
|
||||
@@ -30,11 +30,6 @@ public abstract class JpsCompositeElementBase<Self extends JpsCompositeElementBa
|
||||
myContainer = JpsExElementFactory.getInstance().createContainerCopy(original.myContainer, this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull Self modified) {
|
||||
myContainer.applyChanges(modified.myContainer);
|
||||
}
|
||||
|
||||
@Override
|
||||
@NotNull
|
||||
public JpsElementContainer getContainer() {
|
||||
|
||||
@@ -25,6 +25,4 @@ public abstract class JpsElementContainerEx implements JpsElementContainer {
|
||||
protected abstract Object getDataLock();
|
||||
|
||||
protected abstract Map<JpsElementChildRole<?>, JpsElement> getElementsMap();
|
||||
|
||||
protected abstract void applyChanges(JpsElementContainerEx modified);
|
||||
}
|
||||
|
||||
@@ -39,12 +39,6 @@ public abstract class JpsNamedCompositeElementBase<Self extends JpsNamedComposit
|
||||
return myName;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull Self modified) {
|
||||
super.applyChanges(modified);
|
||||
setName(modified.getName());
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setName(@NlsSafe @NotNull String name) {
|
||||
myName = name;
|
||||
|
||||
@@ -1,10 +1,11 @@
|
||||
// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
|
||||
package org.jetbrains.jps.model.java;
|
||||
|
||||
import java.util.Objects;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.jps.model.ex.JpsElementBase;
|
||||
|
||||
import java.util.Objects;
|
||||
|
||||
public class JavaResourceRootProperties extends JpsElementBase<JavaResourceRootProperties> {
|
||||
private String myRelativeOutputPath = "";
|
||||
private boolean myForGeneratedSources;
|
||||
@@ -45,10 +46,4 @@ public class JavaResourceRootProperties extends JpsElementBase<JavaResourceRootP
|
||||
fireElementChanged();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JavaResourceRootProperties modified) {
|
||||
setRelativeOutputPath(modified.myRelativeOutputPath);
|
||||
setForGeneratedSources(modified.myForGeneratedSources);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -50,10 +50,4 @@ public class JavaSourceRootProperties extends JpsElementBase<JavaSourceRootPrope
|
||||
fireElementChanged();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JavaSourceRootProperties modified) {
|
||||
setPackagePrefix(modified.myPackagePrefix);
|
||||
setForGeneratedSources(modified.myForGeneratedSources);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -23,9 +23,4 @@ public class UnknownSourceRootTypeProperties<Data> extends JpsElementBase<Unknow
|
||||
public UnknownSourceRootTypeProperties<Data> createCopy() {
|
||||
return new UnknownSourceRootTypeProperties<>(myPropertiesData);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull UnknownSourceRootTypeProperties modified) {
|
||||
// not supported
|
||||
}
|
||||
}
|
||||
|
||||
-6
@@ -53,10 +53,4 @@ public class JpsDependencyResolverConfigurationImpl extends JpsElementBase<JpsDe
|
||||
public @NotNull JpsDependencyResolverConfigurationImpl createCopy() {
|
||||
return new JpsDependencyResolverConfigurationImpl(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsDependencyResolverConfigurationImpl modified) {
|
||||
this.checksumVerificationEnabled = modified.checksumVerificationEnabled;
|
||||
this.bindRepositoryEnabled = modified.bindRepositoryEnabled;
|
||||
}
|
||||
}
|
||||
|
||||
+2
-7
@@ -1,10 +1,11 @@
|
||||
// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
|
||||
package org.jetbrains.jps.model.artifact.impl.elements;
|
||||
|
||||
import java.util.Objects;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.jps.model.artifact.elements.JpsExtractedDirectoryPackagingElement;
|
||||
|
||||
import java.util.Objects;
|
||||
|
||||
public class JpsExtractedDirectoryPackagingElementImpl extends JpsFileCopyPackagingElementBase<JpsExtractedDirectoryPackagingElementImpl>
|
||||
implements JpsExtractedDirectoryPackagingElement {
|
||||
private String myPathInJar;
|
||||
@@ -20,12 +21,6 @@ public class JpsExtractedDirectoryPackagingElementImpl extends JpsFileCopyPackag
|
||||
return new JpsExtractedDirectoryPackagingElementImpl(myFilePath, myPathInJar);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsExtractedDirectoryPackagingElementImpl modified) {
|
||||
super.applyChanges(modified);
|
||||
setPathInJar(modified.myPathInJar);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getPathInJar() {
|
||||
return myPathInJar;
|
||||
|
||||
+2
-7
@@ -1,11 +1,11 @@
|
||||
// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
|
||||
package org.jetbrains.jps.model.artifact.impl.elements;
|
||||
|
||||
import java.util.Objects;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.jps.model.artifact.elements.JpsPackagingElement;
|
||||
import org.jetbrains.jps.model.ex.JpsElementBase;
|
||||
|
||||
import java.util.Objects;
|
||||
|
||||
public abstract class JpsFileCopyPackagingElementBase<Self extends JpsFileCopyPackagingElementBase<Self>> extends JpsElementBase<Self> implements
|
||||
JpsPackagingElement {
|
||||
protected String myFilePath;
|
||||
@@ -14,11 +14,6 @@ public abstract class JpsFileCopyPackagingElementBase<Self extends JpsFileCopyPa
|
||||
myFilePath = filePath;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull Self modified) {
|
||||
setFilePath(modified.myFilePath);
|
||||
}
|
||||
|
||||
public String getFilePath() {
|
||||
return myFilePath;
|
||||
}
|
||||
|
||||
+2
-7
@@ -1,10 +1,11 @@
|
||||
// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
|
||||
package org.jetbrains.jps.model.artifact.impl.elements;
|
||||
|
||||
import java.util.Objects;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.jps.model.artifact.elements.JpsFileCopyPackagingElement;
|
||||
|
||||
import java.util.Objects;
|
||||
|
||||
public class JpsFileCopyPackagingElementImpl extends JpsFileCopyPackagingElementBase<JpsFileCopyPackagingElementImpl> implements JpsFileCopyPackagingElement {
|
||||
private String myRenamedOutputFileName;
|
||||
|
||||
@@ -19,12 +20,6 @@ public class JpsFileCopyPackagingElementImpl extends JpsFileCopyPackagingElement
|
||||
return new JpsFileCopyPackagingElementImpl(myFilePath, myRenamedOutputFileName);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsFileCopyPackagingElementImpl modified) {
|
||||
super.applyChanges(modified);
|
||||
setRenamedOutputFileName(modified.myRenamedOutputFileName);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getRenamedOutputFileName() {
|
||||
return myRenamedOutputFileName;
|
||||
|
||||
@@ -5,8 +5,6 @@ import com.intellij.util.containers.CollectionFactory;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.jps.model.*;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collection;
|
||||
import java.util.Map;
|
||||
import java.util.function.Supplier;
|
||||
|
||||
@@ -110,45 +108,4 @@ public class JpsElementContainerImpl extends JpsElementContainerEx implements Jp
|
||||
protected final Map<JpsElementChildRole<?>, JpsElement> getElementsMap() {
|
||||
return myElements;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsElementContainerEx modified) {
|
||||
final Collection<JpsElementChildRole<?>> roles = new ArrayList<>();
|
||||
|
||||
synchronized (myDataLock) {
|
||||
roles.addAll(myElements.keySet());
|
||||
}
|
||||
for (JpsElementChildRole<?> role : roles) {
|
||||
applyChanges(role, modified);
|
||||
}
|
||||
|
||||
roles.clear();
|
||||
synchronized (modified.getDataLock()) {
|
||||
roles.addAll(modified.getElementsMap().keySet());
|
||||
}
|
||||
synchronized (myDataLock) {
|
||||
roles.removeAll(myElements.keySet());
|
||||
}
|
||||
|
||||
for (JpsElementChildRole<?> role : roles) {
|
||||
applyChanges(role, modified);
|
||||
}
|
||||
}
|
||||
|
||||
private <T extends JpsElement> void applyChanges(JpsElementChildRole<T> role, JpsElementContainerEx modified) {
|
||||
final T child = getChild(role);
|
||||
final T modifiedChild = modified.getChild(role);
|
||||
if (child != null && modifiedChild != null) {
|
||||
final JpsElement.BulkModificationSupport modificationSupport = child.getBulkModificationSupport();
|
||||
//noinspection unchecked
|
||||
modificationSupport.applyChanges(modifiedChild);
|
||||
}
|
||||
else if (modifiedChild == null) {
|
||||
removeChild(role);
|
||||
}
|
||||
else {
|
||||
//noinspection unchecked
|
||||
setChild(role, (T)modifiedChild.getBulkModificationSupport().createCopy());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -25,8 +25,4 @@ public final class JpsDummyElementImpl extends JpsElementBase<JpsDummyElementImp
|
||||
public JpsDummyElementImpl createCopy() {
|
||||
return new JpsDummyElementImpl();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsDummyElementImpl modified) {
|
||||
}
|
||||
}
|
||||
|
||||
@@ -75,32 +75,6 @@ public final class JpsElementCollectionImpl<E extends JpsElement> extends JpsEle
|
||||
return new JpsElementCollectionImpl<>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsElementCollectionImpl<E> modified) {
|
||||
Set<E> toRemove = new LinkedHashSet<>(myElements);
|
||||
List<E> toAdd = new ArrayList<>();
|
||||
final Map<E, E> copyToOriginal = modified.myCopyToOriginal;
|
||||
for (E element : modified.myElements) {
|
||||
final E original = copyToOriginal != null ? copyToOriginal.get(element) : null;
|
||||
if (original != null) {
|
||||
//noinspection unchecked
|
||||
((BulkModificationSupport<E>)original.getBulkModificationSupport()).applyChanges(element);
|
||||
toRemove.remove(original);
|
||||
}
|
||||
else {
|
||||
//noinspection unchecked
|
||||
final E copy = (E)element.getBulkModificationSupport().createCopy();
|
||||
toAdd.add(copy);
|
||||
}
|
||||
}
|
||||
for (E e : toRemove) {
|
||||
removeChild(e);
|
||||
}
|
||||
for (E e : toAdd) {
|
||||
addChild(e);
|
||||
}
|
||||
}
|
||||
|
||||
private final class JpsElementIterable<X extends JpsTypedElement<P>, P extends JpsElement> implements Iterable<X> {
|
||||
private final JpsElementType<? extends JpsElement> myType;
|
||||
|
||||
|
||||
-4
@@ -110,8 +110,4 @@ public final class JpsEncodingProjectConfigurationImpl extends JpsElementBase<Jp
|
||||
public JpsEncodingProjectConfigurationImpl createCopy() {
|
||||
return new JpsEncodingProjectConfigurationImpl(myUrlToEncoding, myProjectEncoding);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsEncodingProjectConfigurationImpl modified) {
|
||||
}
|
||||
}
|
||||
|
||||
@@ -45,8 +45,4 @@ public final class JpsExcludePatternImpl extends JpsElementBase<JpsExcludePatter
|
||||
public JpsExcludePatternImpl createCopy() {
|
||||
return new JpsExcludePatternImpl(myBaseDirUrl, myPattern);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsExcludePatternImpl modified) {
|
||||
}
|
||||
}
|
||||
|
||||
@@ -51,9 +51,4 @@ public final class JpsFileTypesConfigurationImpl extends JpsElementBase<JpsFileT
|
||||
fireElementChanged();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsFileTypesConfigurationImpl modified) {
|
||||
setIgnoredPatternString(modified.myIgnoredPatternString);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -33,10 +33,6 @@ public final class JpsGlobalElementReference extends JpsElementReferenceBase<Jps
|
||||
return new JpsGlobalElementReference();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsGlobalElementReference modified) {
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "global ref";
|
||||
|
||||
@@ -33,10 +33,6 @@ public final class JpsProjectElementReference extends JpsElementReferenceBase<Jp
|
||||
return new JpsProjectElementReference();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsProjectElementReference modified) {
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "project ref";
|
||||
|
||||
@@ -49,9 +49,4 @@ public final class JpsSimpleElementImpl<D> extends JpsElementBase<JpsSimpleEleme
|
||||
public JpsSimpleElementImpl<D> createCopy() {
|
||||
return new JpsSimpleElementImpl<>(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsSimpleElementImpl<D> modified) {
|
||||
setData(modified.getData());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -55,13 +55,4 @@ public final class JpsUrlListImpl extends JpsElementBase<JpsUrlListImpl> impleme
|
||||
myUrls.remove(url);
|
||||
fireElementChanged();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsUrlListImpl modified) {
|
||||
if (!myUrls.equals(modified.myUrls)) {
|
||||
myUrls.clear();
|
||||
myUrls.addAll(modified.myUrls);
|
||||
fireElementChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
-5
@@ -37,11 +37,6 @@ public final class JpsRemoteRepositoriesConfigurationImpl extends JpsElementBase
|
||||
return new JpsRemoteRepositoriesConfigurationImpl(repositories);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsRemoteRepositoriesConfigurationImpl modified) {
|
||||
setRepositories(modified.getRepositories());
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<JpsRemoteRepositoryDescription> getRepositories() {
|
||||
return Collections.unmodifiableList(repositories);
|
||||
|
||||
+2
-7
@@ -1,13 +1,14 @@
|
||||
// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
|
||||
package org.jetbrains.jps.model.java.impl;
|
||||
|
||||
import java.util.Objects;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.jps.model.JpsElementCreator;
|
||||
import org.jetbrains.jps.model.ex.JpsElementBase;
|
||||
import org.jetbrains.jps.model.ex.JpsElementChildRoleBase;
|
||||
import org.jetbrains.jps.model.java.ExplodedDirectoryModuleExtension;
|
||||
|
||||
import java.util.Objects;
|
||||
|
||||
public class ExplodedDirectoryModuleExtensionImpl extends JpsElementBase<ExplodedDirectoryModuleExtensionImpl> implements
|
||||
ExplodedDirectoryModuleExtension {
|
||||
private String myExplodedUrl;
|
||||
@@ -53,12 +54,6 @@ public class ExplodedDirectoryModuleExtensionImpl extends JpsElementBase<Explode
|
||||
return new ExplodedDirectoryModuleExtensionImpl(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull ExplodedDirectoryModuleExtensionImpl modified) {
|
||||
setExcludeExploded(modified.myExcludeExploded);
|
||||
setExplodedUrl(modified.myExplodedUrl);
|
||||
}
|
||||
|
||||
public static class ExplodedDirectoryModuleExtensionRole extends JpsElementChildRoleBase<ExplodedDirectoryModuleExtension> implements JpsElementCreator<ExplodedDirectoryModuleExtension> {
|
||||
public static final ExplodedDirectoryModuleExtensionRole INSTANCE = new ExplodedDirectoryModuleExtensionRole();
|
||||
|
||||
|
||||
@@ -37,11 +37,6 @@ public class JavaModuleIndexImpl extends JpsElementBase<JavaModuleIndexImpl> imp
|
||||
return copy;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JavaModuleIndexImpl modified) {
|
||||
// not supported
|
||||
}
|
||||
|
||||
@Nullable
|
||||
@Override
|
||||
public File getModuleInfoFile(@NotNull JpsModule module, boolean forTests) {
|
||||
|
||||
-6
@@ -67,10 +67,4 @@ public class JpsJavaDependencyExtensionImpl extends JpsElementBase<JpsJavaDepend
|
||||
public JpsJavaDependencyExtensionImpl createCopy() {
|
||||
return new JpsJavaDependencyExtensionImpl(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsJavaDependencyExtensionImpl modified) {
|
||||
setExported(modified.myExported);
|
||||
setScope(modified.myScope);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -89,15 +89,6 @@ public final class JpsJavaModuleExtensionImpl extends JpsCompositeElementBase<Jp
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsJavaModuleExtensionImpl modified) {
|
||||
setLanguageLevel(modified.myLanguageLevel);
|
||||
setInheritOutput(modified.myInheritOutput);
|
||||
setExcludeOutput(modified.myExcludeOutput);
|
||||
setOutputUrl(modified.myOutputUrl);
|
||||
setTestOutputUrl(modified.myTestOutputUrl);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isInheritOutput() {
|
||||
return myInheritOutput;
|
||||
|
||||
+2
-7
@@ -2,12 +2,13 @@
|
||||
package org.jetbrains.jps.model.java.impl;
|
||||
|
||||
import com.intellij.openapi.util.Comparing;
|
||||
import java.util.Objects;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.jps.model.ex.JpsElementBase;
|
||||
import org.jetbrains.jps.model.java.JpsJavaProjectExtension;
|
||||
import org.jetbrains.jps.model.java.LanguageLevel;
|
||||
|
||||
import java.util.Objects;
|
||||
|
||||
public class JpsJavaProjectExtensionImpl extends JpsElementBase<JpsJavaProjectExtensionImpl> implements JpsJavaProjectExtension {
|
||||
private String myOutputUrl;
|
||||
private LanguageLevel myLanguageLevel;
|
||||
@@ -51,10 +52,4 @@ public class JpsJavaProjectExtensionImpl extends JpsElementBase<JpsJavaProjectEx
|
||||
fireElementChanged();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsJavaProjectExtensionImpl modified) {
|
||||
setLanguageLevel(modified.myLanguageLevel);
|
||||
setOutputUrl(modified.myOutputUrl);
|
||||
}
|
||||
}
|
||||
|
||||
-5
@@ -34,11 +34,6 @@ public class JpsApplicationRunConfigurationPropertiesImpl extends JpsElementBase
|
||||
return new JpsApplicationRunConfigurationPropertiesImpl(XmlSerializerUtil.createCopy(myState));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsApplicationRunConfigurationPropertiesImpl modified) {
|
||||
XmlSerializerUtil.copyBean(modified.myState, myState);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getMainClass() {
|
||||
return myState.MAIN_CLASS_NAME;
|
||||
|
||||
@@ -62,10 +62,6 @@ public final class JpsLibraryRootImpl extends JpsElementBase<JpsLibraryRootImpl>
|
||||
return new JpsLibraryRootImpl(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsLibraryRootImpl modified) {
|
||||
}
|
||||
|
||||
@Override
|
||||
@NotNull
|
||||
public JpsLibrary getLibrary() {
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
|
||||
package org.jetbrains.jps.model.library.impl.sdk;
|
||||
|
||||
import java.util.Objects;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.jps.model.JpsElement;
|
||||
import org.jetbrains.jps.model.JpsElementFactory;
|
||||
@@ -11,6 +10,8 @@ import org.jetbrains.jps.model.library.sdk.JpsSdk;
|
||||
import org.jetbrains.jps.model.library.sdk.JpsSdkReference;
|
||||
import org.jetbrains.jps.model.library.sdk.JpsSdkType;
|
||||
|
||||
import java.util.Objects;
|
||||
|
||||
public class JpsSdkImpl<P extends JpsElement> extends JpsCompositeElementBase<JpsSdkImpl<P>> implements JpsSdk<P> {
|
||||
private final JpsSdkType<P> mySdkType;
|
||||
private String myHomePath;
|
||||
@@ -58,13 +59,6 @@ public class JpsSdkImpl<P extends JpsElement> extends JpsCompositeElementBase<Jp
|
||||
return (JpsLibraryImpl<JpsSdk<P>>)super.getParent();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsSdkImpl<P> modified) {
|
||||
super.applyChanges(modified);
|
||||
setHomePath(modified.getHomePath());
|
||||
setVersionString(modified.getVersionString());
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getHomePath() {
|
||||
return myHomePath;
|
||||
|
||||
-4
@@ -39,10 +39,6 @@ public class JpsModuleSerializationDataExtensionImpl extends JpsElementBase<JpsM
|
||||
return new JpsModuleSerializationDataExtensionImpl(myBaseDirectory);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsModuleSerializationDataExtensionImpl modified) {
|
||||
}
|
||||
|
||||
@NotNull
|
||||
@Override
|
||||
public File getBaseDirectory() {
|
||||
|
||||
-4
@@ -41,10 +41,6 @@ public class JpsPathVariablesConfigurationImpl extends JpsElementBase<JpsPathVar
|
||||
return new JpsPathVariablesConfigurationImpl(myPathVariables);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsPathVariablesConfigurationImpl modified) {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void addPathVariable(@NotNull String name, @NotNull String value) {
|
||||
myPathVariables.put(name, value);
|
||||
|
||||
-4
@@ -38,10 +38,6 @@ public class JpsProjectSerializationDataExtensionImpl extends JpsElementBase<Jps
|
||||
return new JpsProjectSerializationDataExtensionImpl(myBaseDirectory);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsProjectSerializationDataExtensionImpl modified) {
|
||||
}
|
||||
|
||||
@NotNull
|
||||
@Override
|
||||
public File getBaseDirectory() {
|
||||
|
||||
@@ -67,10 +67,6 @@ class TestCustomSourceRootProperties(initialTestString: String?) : JpsElementBas
|
||||
override fun createCopy(): TestCustomSourceRootProperties {
|
||||
return TestCustomSourceRootProperties(testString)
|
||||
}
|
||||
|
||||
override fun applyChanges(modified: TestCustomSourceRootProperties) {
|
||||
testString = modified.testString
|
||||
}
|
||||
}
|
||||
|
||||
class TestCustomSourceRootPropertiesSerializer(
|
||||
|
||||
-6
@@ -23,12 +23,6 @@ public class JpsIntelliLangConfigurationImpl extends JpsElementBase<JpsIntelliLa
|
||||
return new JpsIntelliLangConfigurationImpl();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsIntelliLangConfigurationImpl modified) {
|
||||
myPatternAnnotationClassName = modified.myPatternAnnotationClassName;
|
||||
myInstrumentationType = modified.myInstrumentationType;
|
||||
}
|
||||
|
||||
@NotNull
|
||||
@Override
|
||||
public String getPatternAnnotationClass() {
|
||||
|
||||
-4
@@ -54,10 +54,6 @@ public final class JpsAntConfigurationImpl extends JpsElementBase<JpsAntConfigur
|
||||
return myProjectDefaultAntName;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsAntConfigurationImpl modified) {
|
||||
}
|
||||
|
||||
@Override
|
||||
@NotNull
|
||||
public Collection<JpsAntBuildFileOptions> getOptionsForAllBuildFiles() {
|
||||
|
||||
-4
@@ -52,10 +52,6 @@ public final class JpsAntInstallationImpl extends JpsElementBase<JpsAntInstallat
|
||||
return myName;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsAntInstallationImpl modified) {
|
||||
}
|
||||
|
||||
@Override
|
||||
public File getAntHome() {
|
||||
return myAntHome;
|
||||
|
||||
-4
@@ -45,8 +45,4 @@ public class JpsGradleModuleExtensionImpl extends JpsElementBase<JpsGradleModule
|
||||
public JpsGradleModuleExtensionImpl createCopy() {
|
||||
return new JpsGradleModuleExtensionImpl(myModuleType);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsGradleModuleExtensionImpl modified) {
|
||||
}
|
||||
}
|
||||
|
||||
-5
@@ -37,11 +37,6 @@ public class GreclipseJpsCompilerSettings extends JpsCompositeElementBase<Grecli
|
||||
return new GreclipseJpsCompilerSettings(mySettings);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull GreclipseJpsCompilerSettings modified) {
|
||||
mySettings = modified.mySettings;
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public static GreclipseSettings getSettings(@NotNull JpsProject project) {
|
||||
GreclipseJpsCompilerSettings extension = project.getContainer().getChild(ROLE);
|
||||
|
||||
-4
@@ -60,10 +60,6 @@ public class JpsGroovySettings extends JpsElementBase<JpsGroovySettings> {
|
||||
return new JpsGroovySettings(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsGroovySettings modified) {
|
||||
}
|
||||
|
||||
@NotNull
|
||||
public static JpsGroovySettings getSettings(@NotNull JpsProject project) {
|
||||
JpsGroovySettings settings = project.getContainer().getChild(ROLE);
|
||||
|
||||
-5
@@ -52,11 +52,6 @@ public class JpsJavaFxArtifactProperties extends JpsElementBase<JpsJavaFxArtifac
|
||||
return new JpsJavaFxArtifactProperties(myState);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsJavaFxArtifactProperties modified) {
|
||||
copyState(modified.myState);
|
||||
}
|
||||
|
||||
public static class MyState {
|
||||
private String myTitle;
|
||||
private String myVendor;
|
||||
|
||||
-5
@@ -36,9 +36,4 @@ public class JPackageArtifactProperties extends JpsElementBase<JPackageArtifactP
|
||||
public @NotNull JPackageArtifactProperties createCopy() {
|
||||
return new JPackageArtifactProperties(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JPackageArtifactProperties modified) {
|
||||
copyState(modified);
|
||||
}
|
||||
}
|
||||
-5
@@ -38,11 +38,6 @@ public class JpsJavaFxPreloaderArtifactProperties extends JpsElementBase<JpsJava
|
||||
return new JpsJavaFxPreloaderArtifactProperties(myState);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsJavaFxPreloaderArtifactProperties modified) {
|
||||
copyState(modified.myState);
|
||||
}
|
||||
|
||||
public String getPreloaderClass() {
|
||||
return myState.getPreloaderClass();
|
||||
}
|
||||
|
||||
-4
@@ -26,8 +26,4 @@ public class JpsMavenModuleExtensionImpl extends JpsElementBase<JpsMavenModuleEx
|
||||
extension.myAnnotationProcessorModules.addAll(this.myAnnotationProcessorModules);
|
||||
return extension;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsMavenModuleExtensionImpl modified) {
|
||||
}
|
||||
}
|
||||
|
||||
-7
@@ -65,13 +65,6 @@ public class JpsUiDesignerConfigurationImpl extends JpsElementBase<JpsUiDesigner
|
||||
return myState.USE_DYNAMIC_BUNDLES;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void applyChanges(@NotNull JpsUiDesignerConfigurationImpl modified) {
|
||||
setCopyFormsRuntimeToOutput(modified.isCopyFormsRuntimeToOutput());
|
||||
setInstrumentClasses(modified.isInstrumentClasses());
|
||||
setUseDynamicBundles(modified.isUseDynamicBundles());
|
||||
}
|
||||
|
||||
public static class UiDesignerConfigurationState {
|
||||
public boolean INSTRUMENT_CLASSES = true;
|
||||
public boolean COPY_FORMS_RUNTIME_TO_OUTPUT = true;
|
||||
|
||||
Reference in New Issue
Block a user