Skip to content

Commit 150b8e4

Browse files
Deleted NGElementUtils.classWithName()
1 parent a9c6351 commit 150b8e4

File tree

1 file changed

+2
-14
lines changed

1 file changed

+2
-14
lines changed

ng-appserver/src/main/java/ng/appserver/templating/NGElementUtils.java

Lines changed: 2 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -101,10 +101,10 @@ public static void addPackage( final String packageName ) {
101101
/**
102102
* @return A class matching classNameToSearch for. Searches by fully qualified class name and simpleName.
103103
*/
104-
private static Class<?> classWithName( String classNameToSearchFor ) {
104+
public static Class classWithNameNullIfNotFound( String classNameToSearchFor ) {
105105
Objects.requireNonNull( classNameToSearchFor );
106106

107-
logger.info( "Searching for class '{}'", classNameToSearchFor );
107+
logger.debug( "Searching for class '{}'", classNameToSearchFor );
108108

109109
for( Class<?> c : _classes ) {
110110
// FIXME: We've disabled this functionality, since we shouldn't be using this functionality to look for a class by a fully qualified name // Hugi 2025-03-16
@@ -132,18 +132,6 @@ private static Class<?> classWithName( String classNameToSearchFor ) {
132132
throw new RuntimeException( "Class not found: " + classNameToSearchFor );
133133
}
134134

135-
/**
136-
* FIXME: This is horrible
137-
*/
138-
public static Class classWithNameNullIfNotFound( String classNameToSearchFor ) {
139-
try {
140-
return classWithName( classNameToSearchFor );
141-
}
142-
catch( RuntimeException e ) {
143-
return null;
144-
}
145-
}
146-
147135
/**
148136
* Maps tag names to their dynamic element names
149137
*

0 commit comments

Comments
 (0)