KABC::FormatFactory Class Reference

Class for loading format plugins. More...

#include <formatfactory.h>

List of all members.

Public Member Functions

 ~FormatFactory ()
Formatformat (const QString &type)
QStringList formats ()
FormatInfo info (const QString &type) const

Static Public Member Functions

static FormatFactoryself ()

Detailed Description

Class for loading format plugins.

Example:

 KABC::FormatFactory *factory = KABC::FormatFactory::self();

 QStringList list = factory->formats();
 QStringList::Iterator it;
 for ( it = list.begin(); it != list.end(); ++it ) {
   KABC::Format *format = factory->format( (*it) );
   // do something with format
 }

Definition at line 95 of file formatfactory.h.


Constructor & Destructor Documentation

FormatFactory::~FormatFactory (  ) 

Destructor.

Definition at line 112 of file formatfactory.cpp.


Member Function Documentation

Format * FormatFactory::format ( const QString &  type  ) 

Returns a pointer to a format object or a null pointer if format type doesn't exist.

Parameters:
type The type of the format, returned by formats()
See also:
info()

Definition at line 144 of file formatfactory.cpp.

QStringList FormatFactory::formats (  ) 

Returns a list of all available format types.

Definition at line 117 of file formatfactory.cpp.

FormatInfo FormatFactory::info ( const QString &  type  )  const

Returns the info structure for a special type.

Parameters:
type The type of the format, returned by formats()
See also:
format()

Definition at line 135 of file formatfactory.cpp.

FormatFactory * FormatFactory::self (  )  [static]

Returns the global format factory.

Definition at line 67 of file formatfactory.cpp.


The documentation for this class was generated from the following files:
KDE Home | KDE Accessibility Home | Description of Access Keys