我在我的插件中使用它:
MavenResourcesExecution mavenResourcesExecution = new MavenResourcesExecution(resources, outputFileDirectory, project, encoding, buildFilters, Collections.<String>emptyList(), session);
try {
mavenResourcesFiltering.filterResources(mavenResourcesExecution);
} catch (MavenFilteringException e) {
e.printStackTrace();
}
并将所有内容写入文件,但是我想将其作为变量检索,而不是将其写入文件。我该怎么做?