private static void writeEffectivePom(MavenProject project,XMLWriter writer) throws MojoExecutionException {
  Model pom=project.getModel();
  cleanModel(pom);
  String effectivePom;
  StringWriter sWriter=new StringWriter();
  MavenXpp3Writer pomWriter=new MavenXpp3Writer();
  try {
    pomWriter.write(sWriter,pom);
  }
 catch (  IOException e) {
    throw new MojoExecutionException("Cannot serialize POM to XML.",e);
  }
  effectivePom=addMavenNamespace(sWriter.toString(),true);
  writeComment(writer,"Effective POM for project \'" + project.getId() + "\'");
  writer.writeMarkup(effectivePom);
}

private static void writeEffectivePom ( MavenProject project , XMLWriter writer ) throws MojoExecutionException { Model pom = project . getModel ( ) ; cleanModel ( pom ) ; String effectivePom ; StringWriter sWriter = new StringWriter ( ) ; MavenXpp3Writer pomWriter = new MavenXpp3Writer ( ) ; try { pomWriter . write ( sWriter , pom ) ; } catch ( IOException e ) { throw new MojoExecutionException ( "Cannot serialize POM to XML." , e ) ; } effectivePom = addMavenNamespace ( sWriter . toString ( ) , true ) ; writeComment ( writer , "Effective POM for project \'" + project . getId ( ) + "\'" ) ; writer . writeMarkup ( effectivePom ) ; }
method from org . apache . maven . plugins . help . effectivepommojo method for writing the effective pom informations of the current build .
