.TH "KSimpleFileFilter" kde3 "11 Jun 2005" "Version Version 3.4.1" "kio Library" \" -*- nroff -*-
.ad l
.nh
.SH NAME
KSimpleFileFilter \- A simple file filter that can filter hidden dot files, by name, by mime type and by mode. A simple file filter.  

.PP
.SH SYNOPSIS
.br
.PP
\fC#include <kfilefilter.h>\fP
.PP
Inherits \fBKFileFilter\fP.
.PP
.SS "Public Member Functions"

.in +1c
.ti -1c
.RI "\fBKSimpleFileFilter\fP ()"
.br
.ti -1c
.RI "virtual void \fBsetFilterDotFiles\fP (bool filter)"
.br
.ti -1c
.RI "bool \fBfilterDotFiles\fP () const "
.br
.ti -1c
.RI "virtual void \fBsetFilterSpecials\fP (bool filter)"
.br
.ti -1c
.RI "bool \fBfilterSpecials\fP () const "
.br
.ti -1c
.RI "void \fBsetNameFilters\fP (const \fBQString\fP &nameFilters, bool caseSensitive, const \fBQChar\fP &separator= ' ')"
.br
.ti -1c
.RI "virtual void \fBsetNameFilters\fP (const \fBQString\fP &nameFilters)"
.br
.ti -1c
.RI "virtual void \fBsetMimeFilters\fP (const \fBQStringList\fP &mimeFilters)"
.br
.ti -1c
.RI "\fBQStringList\fP \fBmimeFilters\fP () const "
.br
.ti -1c
.RI "virtual void \fBsetModeFilter\fP (mode_t mode)"
.br
.ti -1c
.RI "mode_t \fBmodeFilter\fP () const "
.br
.ti -1c
.RI "virtual bool \fBpassesFilter\fP (const \fBKFileItem\fP *item) const "
.br
.in -1c
.SS "Protected Member Functions"

.in +1c
.ti -1c
.RI "virtual void \fBvirtual_hook\fP (int id, void *data)"
.br
.in -1c
.SS "Protected Attributes"

.in +1c
.ti -1c
.RI "\fBQPtrList\fP< \fBQRegExp\fP > \fBm_nameFilters\fP"
.br
.in -1c
.SH "Detailed Description"
.PP 
A simple file filter that can filter hidden dot files, by name, by mime type and by mode. A simple file filter. 
.PP
Definition at line 59 of file kfilefilter.h.
.SH "Constructor & Destructor Documentation"
.PP 
.SS "KSimpleFileFilter::KSimpleFileFilter ()"
.PP
Creates a new filter. 
.PP
By default, it filters only hidden dot files and '.' and '..'. 
.PP
Definition at line 28 of file kfilefilter.cpp.
.PP
References QPtrList::setAutoDelete().
.SH "Member Function Documentation"
.PP 
.SS "void KSimpleFileFilter::setFilterDotFiles (bool filter)\fC [virtual]\fP"
.PP
Enable or disable filtering hidden dot files. 
.PP
This option is enabled by default. 
.PP
\fBParameters:\fP
.RS 4
\fIfilter\fP true to enable filtering dot files, false to disable 
.RE
.PP
\fBSee also:\fP
.RS 4
\fBfilterDotFiles\fP 
.RE
.PP

.PP
Definition at line 40 of file kfilefilter.cpp.
.SS "bool KSimpleFileFilter::filterDotFiles () const\fC [inline]\fP"
.PP
Checks whether filtering dot files is enabled. 
.PP
This option is enabled by default. 
.PP
\fBReturns:\fP
.RS 4
true if filtering is enabled, false otherwise 
.RE
.PP
\fBSee also:\fP
.RS 4
\fBsetFilterDotFiles\fP 
.RE
.PP

.PP
Definition at line 83 of file kfilefilter.h.
.SS "void KSimpleFileFilter::setFilterSpecials (bool filter)\fC [virtual]\fP"
.PP
Filters '.' and '..', default is true. 
.PP
\fBParameters:\fP
.RS 4
\fIfilter\fP true to enable, false otherwise 
.RE
.PP

.PP
Definition at line 45 of file kfilefilter.cpp.
.SS "bool KSimpleFileFilter::filterSpecials () const\fC [inline]\fP"
.PP
Checks whether it filters '.' and '..', default is true. 
.PP
\fBReturns:\fP
.RS 4
true if enabled, false otherwise 
.RE
.PP

.PP
Definition at line 94 of file kfilefilter.h.
.SS "void KSimpleFileFilter::setNameFilters (const \fBQString\fP & nameFilters, bool caseSensitive, const \fBQChar\fP & separator = \fC' '\fP)"
.PP
Sets a list of regular expressions to filter by name. 
.PP
The file will only pass if its name matches one of the regular expressions. 
.PP
\fBParameters:\fP
.RS 4
\fInameFilters\fP a list of regular expressions, separated by the character \fCseparator\fP 
.br
\fIcaseSensitive\fP if true, matches case sensitive. False otherwise 
.br
\fIseparator\fP the separator in the \fCnameFilter\fP 
.RE
.PP
\fBSince:\fP
.RS 4
3.1 
.RE
.PP

.PP
Definition at line 56 of file kfilefilter.cpp.
.PP
References QPtrList::append(), QPtrList::clear(), and QStringList::split().
.PP
Referenced by setNameFilters().
.SS "void KSimpleFileFilter::setNameFilters (const \fBQString\fP & nameFilters)\fC [virtual]\fP"
.PP
Sets a list of regular expressions to filter by name. 
.PP
The file will only pass if its name matches one of the regular expressions. 
.PP
\fBParameters:\fP
.RS 4
\fInameFilters\fP a list of regular expressions, separated by space (' ') 
.RE
.PP

.PP
Definition at line 50 of file kfilefilter.cpp.
.PP
References setNameFilters().
.SS "void KSimpleFileFilter::setMimeFilters (const \fBQStringList\fP & mimeFilters)\fC [virtual]\fP"
.PP
Sets a list of mime filters. 
.PP
A file can only pass if its mime type is contained in this list. 
.PP
\fBParameters:\fP
.RS 4
\fImimeFilters\fP the list of mime types 
.RE
.PP
\fBSee also:\fP
.RS 4
setMimeFilter 
.RE
.PP

.PP
Definition at line 70 of file kfilefilter.cpp.
.PP
References mimeFilters().
.SS "\fBQStringList\fP KSimpleFileFilter::mimeFilters () const\fC [inline]\fP"
.PP
Returns the list of mime types. 
.PP
\fBReturns:\fP
.RS 4
the list of mime types 
.RE
.PP
\fBSee also:\fP
.RS 4
mimeFilter 
.RE
.PP

.PP
Definition at line 131 of file kfilefilter.h.
.PP
Referenced by setMimeFilters().
.SS "void KSimpleFileFilter::setModeFilter (mode_t mode)\fC [virtual]\fP"
.PP
Sets the mode filter. 
.PP
If the \fCmode\fP is 0, the filter is disabled. When enabled, a file will only pass if the files mode ANDed with \fCmode\fP is not zero. 
.PP
\fBParameters:\fP
.RS 4
\fImode\fP the new mode. 0 to disable 
.RE
.PP
\fBSee also:\fP
.RS 4
\fBmodeFilter\fP 
.RE
.PP

.PP
Definition at line 75 of file kfilefilter.cpp.
.SS "mode_t KSimpleFileFilter::modeFilter () const\fC [inline]\fP"
.PP
Returns the mode filter, as set by \fBsetModeFilter()\fP. 
.PP
\fBReturns:\fP
.RS 4
the mode filter, 0 if disabled 
.RE
.PP
\fBSee also:\fP
.RS 4
\fBsetModeFilter\fP 
.RE
.PP

.PP
Definition at line 147 of file kfilefilter.h.
.SS "bool KSimpleFileFilter::passesFilter (const \fBKFileItem\fP * item) const\fC [virtual]\fP"
.PP
Checks the given \fCitem\fP. 
.PP
\fBParameters:\fP
.RS 4
\fIitem\fP the item to filter 
.RE
.PP
\fBReturns:\fP
.RS 4
true if the \fCitem\fP passes the filter, false otherwise 
.RE
.PP

.PP
Implements \fBKFileFilter\fP.
.PP
Definition at line 80 of file kfilefilter.cpp.
.PP
References QString::at(), QPtrListIterator::current(), QPtrList::isEmpty(), and KGlobal::staticQString().

.SH "Author"
.PP 
Generated automatically by Doxygen for kio Library from the source code.
