use of org.eclipse.che.maven.data.MavenWorkspaceCache in project che by eclipse.
the class CheArtifactResolver method isModule.
private boolean isModule(Artifact artifact) {
MavenWorkspaceCache cache = workspaceCache;
if (cache == null) {
return false;
}
Entry entry = cache.findEntry(new MavenKey(artifact.getGroupId(), artifact.getArtifactId(), artifact.getVersion()));
if (entry == null) {
return false;
}
artifact.setResolved(true);
artifact.setFile(entry.getFile(artifact.getType()));
artifact.selectVersion(entry.getKey().getVersion());
return true;
}
use of org.eclipse.che.maven.data.MavenWorkspaceCache in project che by eclipse.
the class MavenServerManagerTest method setUp.
@BeforeMethod
public void setUp() throws Exception {
workspaceCache = new MavenWorkspaceCache();
workspaceCache.put(new MavenKey("org.eclipse.che", "che-ide-subModule", "1.0.0-TEST-SNAPSHOT"), new File(MavenServerManagerTest.class.getResource("/multimoduleProject/subModule/pom.xml").getFile()));
mavenServer = manager.createMavenServer();
mavenServer.customize(workspaceCache, new MyMavenTerminal(), new MyMavenServerProgressNotifier(), true, false);
}
Aggregations