docs: protected Model createEffectivePom( ModelBuildingRequest buildingRequest,
                                                 final boolean embedBuildProfileDependencies, final FlattenMode flattenMode )
          throws MojoExecutionException
      {
          ModelBuildingResult buildingResult;
          try
          {
              ProfileInjector profileInjector = new ProfileInjector()
              {
  
                  public void injectProfile( Model model, Profile profile, ModelBuildingRequest request,
                                             ModelProblemCollector problems )
                  {
                      List<String> activeProfileIds = request.getActiveProfileIds();
                      if ( activeProfileIds.contains( profile.getId() ) )
                      {
                          Properties merged = new Properties();
                          merged.putAll( model.getProperties() );
                          merged.putAll( profile.getProperties() );
                          model.setProperties( merged );
                      }
                  }
              };
              ProfileSelector profileSelector = new ProfileSelector()
              {
                  public List<Profile> getActiveProfiles( Collection<Profile> profiles, ProfileActivationContext context,
                                                          ModelProblemCollector problems )
                  {
                      List<Profile> activeProfiles = new ArrayList<Profile>( profiles.size() );
  
                      for ( Profile profile : profiles )
                      {
                          Activation activation = profile.getActivation();
                          if ( !embedBuildProfileDependencies || isBuildTimeDriven( activation ) )
                          {
                              activeProfiles.add( profile );
                          }
                      }
  
                      return activeProfiles;
                  }
              };
              
              defaultModelBuilder.setProfileInjector( profileInjector ).setProfileSelector( profileSelector );
              //if (flattenMode == FlattenMode.resolveCiFriendliesOnly) {
              //	defaultModelBuilder.setModelInterpolator(new CiModelInterpolator());
              //}
              buildingResult = defaultModelBuilder.build( buildingRequest );
          }
          catch ( ModelBuildingException e )
          {
              throw new MojoExecutionException( e.getMessage(), e );
          }
  
          Model effectivePom = buildingResult.getEffectiveModel();
  
          // LoggingModelProblemCollector problems = new LoggingModelProblemCollector( getLog() );
          // Model interpolatedModel =
          // this.modelInterpolator.interpolateModel( this.project.getOriginalModel(),
          // effectivePom.getProjectDirectory(), buildingRequest, problems );
  
          // remove Repositories from super POM (central)
          effectivePom.setRepositories( createFlattenedRepositories( effectivePom.getRepositories() ) );
          return effectivePom;
      }