+ ##
+ # Regex match for collection UUIDs, returns a regex match object with the
+ # uuid in group 1, empty groups 2 and 3 (for consistency with the match
+ # method above), and (optional) file path within the collection as group
+ # 4.
+ # returns nil for no match.
+ #
+ def self.match_uuid_with_optional_filepath(uuid_with_optional_file)
+ /^([0-9a-z]{5}-4zz18-[0-9a-z]{15})()()(\/.*)?$/.match(uuid_with_optional_file.to_s)
+ end
+
+ ##
+ # Regex match for common image file extensions, returns a regex match object
+ # with the matched extension in group 1; or nil for no match.
+ #
+ # +file+ the file string to match
+ #