Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
QMimeGlobPattern Class Reference

The QMimeGlobPattern class contains the glob pattern for file names for MIME type matching. More...

#include <qmimeglobpattern_p.h>

Collaboration diagram for QMimeGlobPattern:

Public Member Functions

 QMimeGlobPattern (const QString &thePattern, const QString &theMimeType, unsigned theWeight=DefaultWeight, Qt::CaseSensitivity s=Qt::CaseInsensitive)
void swap (QMimeGlobPattern &other) noexcept
bool matchFileName (const QString &inputFileName) const
const QStringpattern () const
unsigned weight () const
const QStringmimeType () const
bool isCaseSensitive () const

Static Public Attributes

static const unsigned MaxWeight = 100
static const unsigned DefaultWeight = 50
static const unsigned MinWeight = 1

Detailed Description

The QMimeGlobPattern class contains the glob pattern for file names for MIME type matching.

\inmodule QtCore

See also
QMimeType, QMimeDatabase, QMimeMagicRuleMatcher, QMimeMagicRule

Definition at line 42 of file qmimeglobpattern_p.h.

Constructor & Destructor Documentation

◆ QMimeGlobPattern()

QMimeGlobPattern::QMimeGlobPattern ( const QString & thePattern,
const QString & theMimeType,
unsigned theWeight = DefaultWeight,
Qt::CaseSensitivity s = Qt::CaseInsensitive )
inlineexplicit

Definition at line 49 of file qmimeglobpattern_p.h.

References QMimeGlobPattern().

Referenced by QMimeGlobPattern().

Here is the call graph for this function:
Here is the caller graph for this function:

Member Function Documentation

◆ isCaseSensitive()

bool QMimeGlobPattern::isCaseSensitive ( ) const
inline

Definition at line 74 of file qmimeglobpattern_p.h.

◆ matchFileName()

bool QMimeGlobPattern::matchFileName ( const QString & inputFileName) const

Definition at line 105 of file qmimeglobpattern.cpp.

◆ mimeType()

const QString & QMimeGlobPattern::mimeType ( ) const
inline

Definition at line 73 of file qmimeglobpattern_p.h.

◆ pattern()

const QString & QMimeGlobPattern::pattern ( ) const
inline

Definition at line 71 of file qmimeglobpattern_p.h.

◆ swap()

void QMimeGlobPattern::swap ( QMimeGlobPattern & other)
inlinenoexcept

Definition at line 60 of file qmimeglobpattern_p.h.

◆ weight()

unsigned QMimeGlobPattern::weight ( ) const
inline

Definition at line 72 of file qmimeglobpattern_p.h.

Referenced by QMimeAllGlobPatterns::addGlob().

Here is the caller graph for this function:

Member Data Documentation

◆ DefaultWeight

const unsigned QMimeGlobPattern::DefaultWeight = 50
static

Definition at line 46 of file qmimeglobpattern_p.h.

◆ MaxWeight

const unsigned QMimeGlobPattern::MaxWeight = 100
static

Definition at line 45 of file qmimeglobpattern_p.h.

◆ MinWeight

const unsigned QMimeGlobPattern::MinWeight = 1
static

Definition at line 47 of file qmimeglobpattern_p.h.


The documentation for this class was generated from the following files: