Example usage for org.apache.shiro.util ClassUtils forName

List of usage examples for org.apache.shiro.util ClassUtils forName

Introduction

In this page you can find the example usage for org.apache.shiro.util ClassUtils forName.

Prototype

public static Class forName(String fqcn) throws UnknownClassException 

Source Link

Document

Attempts to load the specified class name from the current thread's Thread#getContextClassLoader() context class loader , then the current ClassLoader (ClassUtils.class.getClassLoader()), then the system/application ClassLoader (ClassLoader.getSystemClassLoader(), in that order.

Usage

From source file:com.flowlogix.web.services.internal.MixinAdderWorker.java

License:Apache License

/**
 * Determines if the mixin's container is a submit element
 *///from w ww  . j  ava2s.  co  m
public static boolean isCorrectType(Class<?> componentType, String className) {
    Class<?> myClass = ClassUtils.forName(className);
    Class<?> componentClass = ClassUtils.forName(componentType.getName());
    return componentClass.isAssignableFrom(myClass);
}