mirror of https://github.com/apache/openjpa.git
OPENJPA-860 improve trace. Entity class names are printed when found in orm.xml
git-svn-id: https://svn.apache.org/repos/asf/openjpa/trunk@734797 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
88f288b47a
commit
696388049b
|
@ -627,7 +627,7 @@ public abstract class AbstractCFMetaDataFactory
|
||||||
throws IOException {
|
throws IOException {
|
||||||
ClassArgParser cparser = newClassArgParser();
|
ClassArgParser cparser = newClassArgParser();
|
||||||
String[] clss;
|
String[] clss;
|
||||||
Set names = new HashSet();
|
Set<String> names = new HashSet<String>();
|
||||||
if (files != null) {
|
if (files != null) {
|
||||||
File file;
|
File file;
|
||||||
for (Iterator itr = files.iterator(); itr.hasNext();) {
|
for (Iterator itr = files.iterator(); itr.hasNext();) {
|
||||||
|
@ -655,9 +655,10 @@ public abstract class AbstractCFMetaDataFactory
|
||||||
log.trace(_loc.get("scanning-file", file));
|
log.trace(_loc.get("scanning-file", file));
|
||||||
clss = cparser.parseTypeNames(new FileMetaDataIterator
|
clss = cparser.parseTypeNames(new FileMetaDataIterator
|
||||||
(file));
|
(file));
|
||||||
|
List<String> newNames = Arrays.asList(clss);
|
||||||
if (log.isTraceEnabled())
|
if (log.isTraceEnabled())
|
||||||
log.trace(_loc.get("scan-found-names", clss, file));
|
log.trace(_loc.get("scan-found-names", newNames, file));
|
||||||
names.addAll(Arrays.asList(clss));
|
names.addAll(newNames);
|
||||||
File f = AccessController
|
File f = AccessController
|
||||||
.doPrivileged(J2DoPrivHelper
|
.doPrivileged(J2DoPrivHelper
|
||||||
.getAbsoluteFileAction(file));
|
.getAbsoluteFileAction(file));
|
||||||
|
@ -714,9 +715,10 @@ public abstract class AbstractCFMetaDataFactory
|
||||||
if (log.isTraceEnabled())
|
if (log.isTraceEnabled())
|
||||||
log.trace(_loc.get("scanning-url", url));
|
log.trace(_loc.get("scanning-url", url));
|
||||||
clss = cparser.parseTypeNames(new URLMetaDataIterator(url));
|
clss = cparser.parseTypeNames(new URLMetaDataIterator(url));
|
||||||
|
List<String> newNames = Arrays.asList(clss);
|
||||||
if (log.isTraceEnabled())
|
if (log.isTraceEnabled())
|
||||||
log.trace(_loc.get("scan-found-names", clss, url));
|
log.trace(_loc.get("scan-found-names", newNames, url));
|
||||||
names.addAll(Arrays.asList(clss));
|
names.addAll(newNames);
|
||||||
mapPersistentTypeNames(url, clss);
|
mapPersistentTypeNames(url, clss);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -752,9 +754,10 @@ public abstract class AbstractCFMetaDataFactory
|
||||||
url = (URL) mitr.next();
|
url = (URL) mitr.next();
|
||||||
clss = cparser.parseTypeNames(new URLMetaDataIterator
|
clss = cparser.parseTypeNames(new URLMetaDataIterator
|
||||||
(url));
|
(url));
|
||||||
|
List<String> newNames = Arrays.asList(clss);
|
||||||
if (log.isTraceEnabled())
|
if (log.isTraceEnabled())
|
||||||
log.trace(_loc.get("scan-found-names", clss, rsrc));
|
log.trace(_loc.get("scan-found-names", clss, rsrc));
|
||||||
names.addAll(Arrays.asList(clss));
|
names.addAll(newNames);
|
||||||
mapPersistentTypeNames(url, clss);
|
mapPersistentTypeNames(url, clss);
|
||||||
}
|
}
|
||||||
mitr.close();
|
mitr.close();
|
||||||
|
|
Loading…
Reference in New Issue