Example usage for org.apache.wicket.request.resource UrlResourceReference getUrl

List of usage examples for org.apache.wicket.request.resource UrlResourceReference getUrl

Introduction

In this page you can find the example usage for org.apache.wicket.request.resource UrlResourceReference getUrl.

Prototype

public final Url getUrl() 

Source Link

Usage

From source file:org.onehippo.cms7.ckeditor.CKEditorConstants.java

License:Apache License

/**
 * Checks whether a CKEditor resource reference exists on the class path.
 * @param ref a CKEditor resource reference.
 *///from   www .j a v a 2s.co  m
public static boolean existsOnClassPath(final UrlResourceReference ref) {
    final String path = ref.getUrl().getPath();
    final InputStream resource = CKEditorConstants.class.getResourceAsStream("/" + path);
    IOUtils.closeQuietly(resource);
    return resource != null;
}