static String toPath( Model model ) { String path = ""; if ( model != null ) { File pomFile = model.getPomFile(); if ( pomFile != null ) { path = pomFile.getAbsolutePath(); } } return path; }
/** * Creates a user-friendly source hint for the specified model. * * @param model The model to create a source hint for, may be {@code null}. * @return The user-friendly source hint, never {@code null}. */ static String toSourceHint( Model model ) { if ( model == null ) { return ""; } StringBuilder buffer = new StringBuilder( 128 ); buffer.append( toId( model ) ); File pomFile = model.getPomFile(); if ( pomFile != null ) { buffer.append( " (" ).append( pomFile ).append( ')' ); } return buffer.toString(); }
private void populateReactorModelPool( ReactorModelPool reactorModelPool, List<InterimResult> interimResults ) { for ( InterimResult interimResult : interimResults ) { Model model = interimResult.result.getEffectiveModel(); reactorModelPool.put( model.getGroupId(), model.getArtifactId(), model.getVersion(), model.getPomFile() ); populateReactorModelPool( reactorModelPool, interimResult.modules ); } }
project.setFile( model.getPomFile() );
candidateSource = new FileModelSource( candidateModel.getPomFile() );
File parentPomFile = result.getRawModel( parentModelId ).getPomFile(); MavenProject parent = projects.get( parentModelId ); if ( parent == null && buildParentIfNotExisting )
File pomFile = parentData.getModel().getPomFile(); if ( pomFile != null )
interpolatedModel.setPomFile( model.getPomFile() );
/** * Create a project with only a Model. Only used by tests currently. * @param model the Model to use. * @throws ManipulationException if an error occurs. */ public Project( final Model model ) throws ManipulationException { this( model.getPomFile(), model ); }
@Override public File get( Model model ) { return model.getPomFile(); }
@Override public File getPomFile() { return delegate.getPomFile(); }
if (model.getPomFile() != null) { Xpp3Dom nativePom = new Xpp3Dom("nativePom"); nativePom.setValue(model.getPomFile().getName()); config.addChild(nativePom);
public String getPath() { if (model.getPomFile() != null) { return model.getPomFile().getParentFile().getAbsolutePath(); } else { return null; } }
static String toPath( Model model ) { String path = ""; if ( model != null ) { File pomFile = model.getPomFile(); if ( pomFile != null ) { path = pomFile.getAbsolutePath(); } } return path; }
public ModelLoaderEventBuilder withModel( final Model model ) throws ProjectToolsException { this.model = model; this.key = new FullProjectKey( model ); this.pom = model.getPomFile(); return this; }
static void normalizePath(Model model) { if (model != null) { File f = model.getPomFile(); if (f != null) { model.setPomFile(FileUtil.normalizeFile(f)); } } }
private InputLocation getEmptyLocation(MavenProject mavenProject) { final InputSource source = new InputSource(); source.setLocation(mavenProject.getOriginalModel().getPomFile() + ""); return new InputLocation(0, 0, source); } }
private InputLocation getEmptyLocation(MavenProject mavenProject) { final InputSource source = new InputSource(); source.setLocation(mavenProject.getOriginalModel().getPomFile() + ""); return new InputLocation(0, 0, source); } }
private InputLocation getEmptyLocation(MavenProject mavenProject) { final InputSource source = new InputSource(); source.setLocation(mavenProject.getOriginalModel().getPomFile() + ""); return new InputLocation(0, 0, source); } }
private InputLocation getEmptyLocation(MavenProject mavenProject) { final InputSource source = new InputSource(); source.setLocation(mavenProject.getOriginalModel().getPomFile() + ""); return new InputLocation(0, 0, source); } }