in src/main/java/org/apache/maven/plugins/ejb/EjbMojo.java [438:456]
private void filterDeploymentDescriptor(File deploymentDescriptor) throws MavenFilteringException, IOException {
getLog().debug("Filtering deployment descriptor.");
MavenResourcesExecution mavenResourcesExecution = new MavenResourcesExecution();
mavenResourcesExecution.setEscapeString(escapeString);
List<FilterWrapper> filterWrappers = mavenFileFilter.getDefaultFilterWrappers(
project, filters, escapeBackslashesInFilePath, this.session, mavenResourcesExecution);
// Create a temporary file that we can copy-and-filter
File unfilteredDeploymentDescriptor = new File(sourceDirectory, ejbJar + ".unfiltered");
FileUtils.copyFile(deploymentDescriptor, unfilteredDeploymentDescriptor);
mavenFileFilter.copyFile(
unfilteredDeploymentDescriptor,
deploymentDescriptor,
true,
filterWrappers,
getEncoding(unfilteredDeploymentDescriptor));
// Remove the temporary file
FileUtils.forceDelete(unfilteredDeploymentDescriptor);
}