Extracted getFileName to CachedFile class.