From f8a208531bc9128ab94dbaba6e6561151bb4f7dc Mon Sep 17 00:00:00 2001 From: Anton Korneta Date: Mon, 2 May 2016 17:38:10 +0300 Subject: [PATCH] Fix source storage field naming --- .../server/model/impl/ProjectConfigImpl.java | 31 +++++-------------- 1 file changed, 7 insertions(+), 24 deletions(-) diff --git a/wsmaster/che-core-api-workspace/src/main/java/org/eclipse/che/api/workspace/server/model/impl/ProjectConfigImpl.java b/wsmaster/che-core-api-workspace/src/main/java/org/eclipse/che/api/workspace/server/model/impl/ProjectConfigImpl.java index a8baa87bf2..b76c25dfbd 100644 --- a/wsmaster/che-core-api-workspace/src/main/java/org/eclipse/che/api/workspace/server/model/impl/ProjectConfigImpl.java +++ b/wsmaster/che-core-api-workspace/src/main/java/org/eclipse/che/api/workspace/server/model/impl/ProjectConfigImpl.java @@ -36,8 +36,7 @@ public class ProjectConfigImpl implements ProjectConfig { private String type; private List mixins; private Map> attributes; - private List modules; - private SourceStorageImpl storage; + private SourceStorageImpl source; //private String contentRoot; public ProjectConfigImpl() { @@ -49,7 +48,6 @@ public class ProjectConfigImpl implements ProjectConfig { description = projectConfig.getDescription(); type = projectConfig.getType(); mixins = new ArrayList<>(projectConfig.getMixins()); -// modules = new ArrayList<>(projectConfig.getModules() != null ? projectConfig.getModules() : Collections.emptyList()); attributes = projectConfig.getAttributes() .entrySet() .stream() @@ -58,7 +56,7 @@ public class ProjectConfigImpl implements ProjectConfig { SourceStorage sourceStorage = projectConfig.getSource(); if (sourceStorage != null) { - storage = new SourceStorageImpl(sourceStorage.getType(), sourceStorage.getLocation(), sourceStorage.getParameters()); + source = new SourceStorageImpl(sourceStorage.getType(), sourceStorage.getLocation(), sourceStorage.getParameters()); } // contentRoot = projectConfig.getContentRoot(); @@ -120,25 +118,13 @@ public class ProjectConfigImpl implements ProjectConfig { return attributes; } -// @Override -// public List getModules() { -// if (modules == null) { -// modules = new ArrayList<>(); -// } -// return modules; -// } - -// public void setModules(List modules) { -// this.modules = modules; -// } - public void setAttributes(Map> attributes) { this.attributes = attributes; } @Override public SourceStorage getSource() { - return storage; + return source; } // @Override @@ -151,7 +137,7 @@ public class ProjectConfigImpl implements ProjectConfig { // } public void setSource(SourceStorageImpl sourceStorage) { - this.storage = sourceStorage; + this.source = sourceStorage; } @Override @@ -165,8 +151,7 @@ public class ProjectConfigImpl implements ProjectConfig { && Objects.equals(type, other.type) && getMixins().equals(other.getMixins()) && getAttributes().equals(other.getAttributes()) -// && getModules().equals(other.getModules()) - && Objects.equals(storage, other.getSource()); + && Objects.equals(source, other.getSource()); //&& Objects.equals(contentRoot, other.getContentRoot()); } @@ -179,8 +164,7 @@ public class ProjectConfigImpl implements ProjectConfig { hash = hash * 31 + Objects.hashCode(type); hash = hash * 31 + getMixins().hashCode(); hash = hash * 31 + getAttributes().hashCode(); -// hash = hash * 31 + getModules().hashCode(); - hash = hash * 31 + Objects.hashCode(storage); + hash = hash * 31 + Objects.hashCode(source); //hash = hash * 31 + Objects.hashCode(contentRoot); return hash; } @@ -194,8 +178,7 @@ public class ProjectConfigImpl implements ProjectConfig { ", type='" + type + '\'' + ", mixins=" + mixins + ", attributes=" + attributes + - ", modules=" + modules + - ", storage=" + storage + + ", source=" + source + // ", contentRoot='" + contentRoot + '\'' + '}'; }