File tree 2 files changed +15
-5
lines changed
src/main/java/com/ethlo/persistence/tools/eclipselink
2 files changed +15
-5
lines changed Original file line number Diff line number Diff line change 3
3
<modelVersion >4.0.0</modelVersion >
4
4
<groupId >com.ethlo.persistence.tools</groupId >
5
5
<artifactId >eclipselink-maven-plugin</artifactId >
6
- <version >3.0.1 </version >
6
+ <version >3.0.2 </version >
7
7
<packaging >maven-plugin</packaging >
8
8
<name >Eclipselink Maven Plugin</name >
9
9
<description >Maven Plugin for Eclipselink supporting static weaving, meta-model generation and DDL generation
Original file line number Diff line number Diff line change @@ -193,7 +193,17 @@ public void execute() throws MojoExecutionException
193
193
194
194
private Set <File > getSourceFiles ()
195
195
{
196
- if (source == null || !source .exists ())
196
+ final Set <File > fromSource = getFilesFromDirectory (source );
197
+ final Set <File > fromGenerated = getFilesFromDirectory (generatedSourcesDirectory );
198
+ final Set <File > all = new TreeSet <>();
199
+ all .addAll (fromSource );
200
+ all .addAll (fromGenerated );
201
+ return all ;
202
+ }
203
+
204
+ private Set <File > getFilesFromDirectory (File dir )
205
+ {
206
+ if (dir == null || !dir .exists ())
197
207
{
198
208
return new TreeSet <>();
199
209
}
@@ -208,12 +218,12 @@ private Set<File> getSourceFiles()
208
218
}
209
219
}
210
220
211
- Set <File > files = new HashSet <>();
212
- final Scanner scanner = buildContext .newScanner (source );
221
+ final Set <File > files = new HashSet <>();
222
+ final Scanner scanner = buildContext .newScanner (dir );
213
223
scanner .setIncludes (filters );
214
224
scanner .scan ();
215
225
216
- String [] includedFiles = scanner .getIncludedFiles ();
226
+ final String [] includedFiles = scanner .getIncludedFiles ();
217
227
if (includedFiles != null )
218
228
{
219
229
for (String includedFile : includedFiles )
You can’t perform that action at this time.
0 commit comments