mirror of https://github.com/apache/maven.git
Previously removed MavenProject.writeModel, but found a plugin using this method. Added it back in.
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@694669 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
f2e9e6810a
commit
d295ab3a18
|
@ -54,6 +54,7 @@ import org.apache.maven.model.ReportSet;
|
|||
import org.apache.maven.model.Reporting;
|
||||
import org.apache.maven.model.Resource;
|
||||
import org.apache.maven.model.Scm;
|
||||
import org.apache.maven.model.io.xpp3.MavenXpp3Writer;
|
||||
import org.apache.maven.project.artifact.ActiveProjectArtifact;
|
||||
import org.apache.maven.project.artifact.InvalidDependencyVersionException;
|
||||
import org.apache.maven.project.artifact.MavenMetadataSource;
|
||||
|
@ -62,6 +63,7 @@ import org.codehaus.plexus.util.xml.Xpp3Dom;
|
|||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
import java.io.Writer;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collections;
|
||||
import java.util.HashMap;
|
||||
|
@ -1843,6 +1845,14 @@ public class MavenProject
|
|||
return sb.toString();
|
||||
}
|
||||
|
||||
public void writeModel( Writer writer )
|
||||
throws IOException
|
||||
{
|
||||
MavenXpp3Writer pomWriter = new MavenXpp3Writer();
|
||||
pomWriter.write( writer, getModel() );
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @throws CloneNotSupportedException
|
||||
* @since 2.0.9
|
||||
|
|
Loading…
Reference in New Issue