Locating resources can take a significant amount of time, especially since there are often several CSS, JavaScript and image resources on any given page. To facilitate localization and styling, Wicket will usually make several attempts at locating each resource (i.e. first with an "en_US" suffix, then "en", and so on); multiply these attempts by the number of resources on the page and this starts to add up.
This locator mitigates this problem by caching (indefinitely) references to {@link UrlResourceStream} and {@link FileResourceStream} objects as they are found, and{@link NullResourceStreamReference} for all which are missing so they are not looked up again andagain.