public static boolean isFile(final Resource resource) {
        try {
            resource.getFile();
            return true;
        } catch (final Exception e) {
            LOGGER.trace(e.getMessage());
        }
        return false;
    }
Is file boolean.

@param resource the resource
@return true/false
core/cas-server-core-util-api/src/main/java/org/apereo/cas/util/ResourceUtils.java