Search in sources :

Example 1 with PathTranslator

use of org.apache.maven.project.path.PathTranslator in project intellij-community by JetBrains.

the class Maven3ServerEmbedderImpl method interpolateAndAlignModel.

@NotNull
public static MavenModel interpolateAndAlignModel(MavenModel model, File basedir) throws RemoteException {
    Model result = MavenModelConverter.toNativeModel(model);
    result = doInterpolate(result, basedir);
    PathTranslator pathTranslator = new DefaultPathTranslator();
    pathTranslator.alignToBaseDirectory(result, basedir);
    return MavenModelConverter.convertModel(result, null);
}
Also used : DefaultPathTranslator(org.apache.maven.project.path.DefaultPathTranslator) PathTranslator(org.apache.maven.project.path.PathTranslator) DefaultPathTranslator(org.apache.maven.project.path.DefaultPathTranslator) Model(org.apache.maven.model.Model) NotNull(org.jetbrains.annotations.NotNull)

Example 2 with PathTranslator

use of org.apache.maven.project.path.PathTranslator in project intellij-community by JetBrains.

the class Maven2ServerEmbedderImpl method interpolateAndAlignModel.

@NotNull
public static MavenModel interpolateAndAlignModel(MavenModel model, File basedir) throws RemoteException {
    Model result = Maven2ModelConverter.toNativeModel(model);
    result = doInterpolate(result, basedir);
    PathTranslator pathTranslator = new DefaultPathTranslator();
    pathTranslator.alignToBaseDirectory(result, basedir);
    return Maven2ModelConverter.convertModel(result, null);
}
Also used : DefaultPathTranslator(org.apache.maven.project.path.DefaultPathTranslator) PathTranslator(org.apache.maven.project.path.PathTranslator) DefaultPathTranslator(org.apache.maven.project.path.DefaultPathTranslator) Model(org.apache.maven.model.Model) NotNull(org.jetbrains.annotations.NotNull)

Example 3 with PathTranslator

use of org.apache.maven.project.path.PathTranslator in project intellij-community by JetBrains.

the class Maven30ServerEmbedderImpl method interpolateAndAlignModel.

@NotNull
public static MavenModel interpolateAndAlignModel(MavenModel model, File basedir) throws RemoteException {
    Model result = MavenModelConverter.toNativeModel(model);
    result = doInterpolate(result, basedir);
    PathTranslator pathTranslator = new DefaultPathTranslator();
    pathTranslator.alignToBaseDirectory(result, basedir);
    return MavenModelConverter.convertModel(result, null);
}
Also used : DefaultPathTranslator(org.apache.maven.project.path.DefaultPathTranslator) PathTranslator(org.apache.maven.project.path.PathTranslator) DefaultPathTranslator(org.apache.maven.project.path.DefaultPathTranslator) Model(org.apache.maven.model.Model) NotNull(org.jetbrains.annotations.NotNull)

Aggregations

Model (org.apache.maven.model.Model)3 DefaultPathTranslator (org.apache.maven.project.path.DefaultPathTranslator)3 PathTranslator (org.apache.maven.project.path.PathTranslator)3 NotNull (org.jetbrains.annotations.NotNull)3