You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4j-dev@logging.apache.org by Gary Gregory <ga...@gmail.com> on 2016/09/05 21:36:15 UTC

Inline org.apache.logging.log4j.core.util.Loader.loadClass(String)?

We have the Core API
org.apache.logging.log4j.core.util.Loader.loadClass(String) that delegates
to the API module:

    public static Class<?> loadClass(final String className) throws
ClassNotFoundException {
        return LoaderUtil.loadClass(className);
    }

Why bother having this method?

Gary

-- 
E-Mail: garydgregory@gmail.com | ggregory@apache.org
Java Persistence with Hibernate, Second Edition
<http://www.manning.com/bauer3/>
JUnit in Action, Second Edition <http://www.manning.com/tahchiev/>
Spring Batch in Action <http://www.manning.com/templier/>
Blog: http://garygregory.wordpress.com
Home: http://garygregory.com/
Tweet! http://twitter.com/GaryGregory

Re: Inline org.apache.logging.log4j.core.util.Loader.loadClass(String)?

Posted by Gary Gregory <ga...@gmail.com>.
I in-lined the method and removed it from Core.

Gary

On Tue, Sep 6, 2016 at 1:10 AM, Matt Sicker <bo...@gmail.com> wrote:

> The core class is older than the api class. It was left there for a while
> but can probably be pruned down.
>
> On 5 September 2016 at 16:36, Gary Gregory <ga...@gmail.com> wrote:
>
>> We have the Core API org.apache.logging.log4j.core.
>> util.Loader.loadClass(String) that delegates to the API module:
>>
>>     public static Class<?> loadClass(final String className) throws
>> ClassNotFoundException {
>>         return LoaderUtil.loadClass(className);
>>     }
>>
>> Why bother having this method?
>>
>> Gary
>>
>> --
>> E-Mail: garydgregory@gmail.com | ggregory@apache.org
>> Java Persistence with Hibernate, Second Edition
>> <http://www.manning.com/bauer3/>
>> JUnit in Action, Second Edition <http://www.manning.com/tahchiev/>
>> Spring Batch in Action <http://www.manning.com/templier/>
>> Blog: http://garygregory.wordpress.com
>> Home: http://garygregory.com/
>> Tweet! http://twitter.com/GaryGregory
>>
>
>
>
> --
> Matt Sicker <bo...@gmail.com>
>



-- 
E-Mail: garydgregory@gmail.com | ggregory@apache.org
Java Persistence with Hibernate, Second Edition
<http://www.manning.com/bauer3/>
JUnit in Action, Second Edition <http://www.manning.com/tahchiev/>
Spring Batch in Action <http://www.manning.com/templier/>
Blog: http://garygregory.wordpress.com
Home: http://garygregory.com/
Tweet! http://twitter.com/GaryGregory

Re: Inline org.apache.logging.log4j.core.util.Loader.loadClass(String)?

Posted by Matt Sicker <bo...@gmail.com>.
The core class is older than the api class. It was left there for a while
but can probably be pruned down.

On 5 September 2016 at 16:36, Gary Gregory <ga...@gmail.com> wrote:

> We have the Core API org.apache.logging.log4j.core.
> util.Loader.loadClass(String) that delegates to the API module:
>
>     public static Class<?> loadClass(final String className) throws
> ClassNotFoundException {
>         return LoaderUtil.loadClass(className);
>     }
>
> Why bother having this method?
>
> Gary
>
> --
> E-Mail: garydgregory@gmail.com | ggregory@apache.org
> Java Persistence with Hibernate, Second Edition
> <http://www.manning.com/bauer3/>
> JUnit in Action, Second Edition <http://www.manning.com/tahchiev/>
> Spring Batch in Action <http://www.manning.com/templier/>
> Blog: http://garygregory.wordpress.com
> Home: http://garygregory.com/
> Tweet! http://twitter.com/GaryGregory
>



-- 
Matt Sicker <bo...@gmail.com>