MimeCache.findMimeTypesBySuffix

Find all MIME type alternatives for fileName using suffix patterns like *.cpp. Due to mime cache format characteristics it uses output range instead of returning the input one.

class MimeCache
@trusted const
void
findMimeTypesBySuffix
(
OutRange
)
(
scope const(char)[] fileName
,
OutRange sink
)
if (
isOutputRange!(OutRange, MimeTypeAlternativeByName)
)

Parameters

fileName const(char)[]

name to match against suffix patterns.

sink OutRange

output range where MimeTypeAlternativeByName objects with pattern set to suffix matching fileName will be put. Note: pattern property of MimeTypeAlternativeByName objects will not have leading "*" to avoid allocating.

Meta