class KURIFilterPlugin

# class KURIFilterPlugin | Abstract class for URI filter plugins. More...
Contains pure virtuals
Definition | `#include <kurifilter.h>`
Inherits | QObject (qt) [public ]
List of all Methods
Annotated List
Files
Globals
Hierarchy
Index

#### Public Methods

- KURIFilterPlugin ( QObject *parent = 0, const char *name = 0, double pri = 1.0 )
- virtual QString name () const
- virtual double priority () const
- virtual bool filterURI ( KURIFilterData& data ) const
- virtual KCModule * configModule ( QWidget*, const char* ) const
- virtual QString configName () const

#### Protected Methods

- void setFilteredURI ( KURIFilterData& data, const KURL& uri ) const
- void setErrorMsg ( KURIFilterData& data, const QString& errmsg ) const
- void setURIType ( KURIFilterData& data, KURIFilterData::URITypes type) const
- void setArguments ( KURIFilterData& data, const QString& args ) const
- virtual void virtual_hook ( int id, void* data )

#### Protected Members

- QString m_strName
- double m_dblPriority

## Detailed Description

Base class for URI filter plugins.

This class applies a single filter to a URI. All plugins designed to provide URI filtering functionalities should inherit from this abstract class and provide a specific filtering implementation.

All inheriting classes need to implement the pure virtual function filterURI. Otherwise, they would also become abstract.

KURIFilterPlugin ( QObject *parent = 0, const char *name = 0, double pri = 1.0 ) | ### KURIFilterPlugin

Constructs a filter plugin with a given name and priority.

Parameters:

parent | the parent object.
name | the name of the plugin.
pri | the priority of the plugin.

QString name () | ### name

[const virtual]

Returns the filter's name.

Returns: A string naming the filter.

double priority () | ### priority

[const virtual]

Returns the filter's priority.

Each filter has an assigned priority, a float from 0 to 1. Filters with the lowest priority are first given a chance to filter a URI.

Returns: The priority of the filter.

bool filterURI ( KURIFilterData& data ) | ### filterURI

[const pure virtual]

Filters a URI.

Parameters:

data | the URI data to be filtered.

Returns: A boolean indicating whether the URI has been changed.

KCModule * configModule ( QWidget*, const char* ) | ### configModule

[const virtual]

Creates a configuration module for the filter.

It is the responsability of the caller to delete the module once it is not needed anymore.

Returns: A configuration module, `null` if the filter isn't configurable.

QString configName () | ### configName

[const virtual]

Returns the name of the configuration module for the filter.

Returns: the name of a configuration module or `null` if none.

void setFilteredURI ( KURIFilterData& data, const KURL& uri ) | ### setFilteredURI

[protected const]

Sets the the URL in `data` to `uri`.

void setErrorMsg ( KURIFilterData& data, const QString& errmsg ) | ### setErrorMsg

[protected const]

Sets the error message in `data` to `errormsg`.

void setURIType ( KURIFilterData& data, KURIFilterData::URITypes type) | ### setURIType

[protected const]

Sets the URI type in `data` to `type`.

void setArguments ( KURIFilterData& data, const QString& args ) | ### setArguments

[protected const]

Sets the arguments and options string in `data` to `args` if any were found during filterting.

QString m_strName | ### m_strName

[protected]

double m_dblPriority | ### m_dblPriority

[protected]

void virtual_hook ( int id, void* data ) | ### virtual_hook

[protected virtual]

Generated by: root on macppc.ports.openbsd.org on Sat Sep 6 10:36:57 2003, using kdoc 2.0a54.