A public method exposing the knowledge of the path extension strategy to
resolve file extensions to a MediaType in this case for a given
Resource. The method first looks up any explicitly registered
file extensions first and then falls back on MediaTypeFactory if available.
resource - the resource to look up
the MediaType for the extension, or null if none found