AccountSetupItem Class Reference

This class is used in ConfigAccounts to show the available accounts in the list view and to store an account setup. More...

#include <accountsetupitem.h>

List of all members.

Public Member Functions

 AccountSetupItem (QTreeWidget *parent)
 Constructor.
 AccountSetupItem (QTreeWidget *parent, const QString &name)
 Constructor.
 ~AccountSetupItem ()
 Destructor.
void setAccountName (const QString &name)
 Sets account name.
QString getAccountName () const
 Returns the account name.
void setServer (const QString &server)
 Sets the server.
QString getServer () const
 Returns the server.
void setProtocol (const QString &protocol)
 Sets the protocol.
QString getProtocol () const
 Returns the protocol.
void setPort (int port)
 Sets the port number.
int getPort () const
 Returns the port number.
void setUser (const QString &user)
 Sets the user name.
QString getUser () const
 Returns the user name.
void setPassword (const QString &password)
 Sets the password.
QString getPassword () const
 Returns the password.
void setPasswordStorageType (int type)
 Sets the password storage type.
int getPasswordStorageType () const
 Returns the password storage type.
void setActive (bool active)
 Sets whether the account is active.
bool getActive () const
 Returns whether the account is active.
void setTransferSecurity (int type)
 Sets the transfer security.
int getTransferSecurity () const
 Returns the transfer security.
void save () const
 Saves this account into applications config.
void load ()
 Loads the options of this account from the application config.
void print ()
 Prints the account settings to stdout.
void setUnsecureLoginAllowed (bool allowed)
 Sets whether an unsecure login is allowed.
bool getUnsecureLoginAllowed () const
 Return whether an unsecure login is allowed.

Protected Member Functions

void init ()
 Initializes the object.


Detailed Description

This class is used in ConfigAccounts to show the available accounts in the list view and to store an account setup.

Author:
Ulrich Weigelt <ulrich.weigelt@gmx.de>

Definition at line 43 of file accountsetupitem.h.


Constructor & Destructor Documentation

AccountSetupItem::AccountSetupItem ( QTreeWidget *  parent  ) 

Constructor.

Parameters:
parent the list view

Definition at line 20 of file accountsetupitem.cpp.

AccountSetupItem::AccountSetupItem ( QTreeWidget *  parent,
const QString &  name 
)

Constructor.

Parameters:
parent the list view
name account name

Definition at line 27 of file accountsetupitem.cpp.


Member Function Documentation

void AccountSetupItem::setAccountName ( const QString &  name  ) 

Sets account name.

Parameters:
name account name

Definition at line 65 of file accountsetupitem.cpp.

QString AccountSetupItem::getAccountName (  )  const

Returns the account name.

Returns:
account name

Definition at line 70 of file accountsetupitem.cpp.

void AccountSetupItem::setServer ( const QString &  server  ) 

Sets the server.

Parameters:
server server

Definition at line 75 of file accountsetupitem.cpp.

QString AccountSetupItem::getServer (  )  const

Returns the server.

Returns:
server

Definition at line 80 of file accountsetupitem.cpp.

void AccountSetupItem::setProtocol ( const QString &  protocol  ) 

Sets the protocol.

Parameters:
protocol protocol

Definition at line 85 of file accountsetupitem.cpp.

QString AccountSetupItem::getProtocol (  )  const

Returns the protocol.

Returns:
protocol

Definition at line 90 of file accountsetupitem.cpp.

void AccountSetupItem::setPort ( int  port  ) 

Sets the port number.

Parameters:
port port number

Definition at line 95 of file accountsetupitem.cpp.

int AccountSetupItem::getPort (  )  const

Returns the port number.

Returns:
port number (0..65535)

Definition at line 103 of file accountsetupitem.cpp.

void AccountSetupItem::setUser ( const QString &  user  ) 

Sets the user name.

Parameters:
user user name

Definition at line 108 of file accountsetupitem.cpp.

QString AccountSetupItem::getUser (  )  const

Returns the user name.

Returns:
user name

Definition at line 113 of file accountsetupitem.cpp.

void AccountSetupItem::setPassword ( const QString &  password  ) 

Sets the password.

Parameters:
password password

Definition at line 118 of file accountsetupitem.cpp.

QString AccountSetupItem::getPassword (  )  const

Returns the password.

Returns:
password

Definition at line 123 of file accountsetupitem.cpp.

void AccountSetupItem::setPasswordStorageType ( int  type  ) 

Sets the password storage type.

See constants.h for valid values

Parameters:
type password storage type (CONFIG_VALUE_ACCOUNT_PASSWORD_DONT_SAVE, CONFIG_VALUE_ACCOUNT_PASSWORD_SAVE_FILE or CONFIG_VALUE_ACCOUNT_PASSWORD_SAVE_KWALLET)

Definition at line 128 of file accountsetupitem.cpp.

int AccountSetupItem::getPasswordStorageType (  )  const

Returns the password storage type.

See constants.h for valid values (CONFIG_VALUE_ACCOUNT_PASSWORD_...)

Returns:
storage type

Definition at line 136 of file accountsetupitem.cpp.

void AccountSetupItem::setActive ( bool  active  ) 

Sets whether the account is active.

Parameters:
active TRUE - account is active; FALSE - account is not active

Definition at line 141 of file accountsetupitem.cpp.

bool AccountSetupItem::getActive (  )  const

Returns whether the account is active.

Returns:
TRUE - account is active

FALSE - account is not active

Definition at line 146 of file accountsetupitem.cpp.

void AccountSetupItem::setTransferSecurity ( int  type  ) 

Sets the transfer security.

See constants.h for valid values.

Parameters:
type transfer security type (CONFIG_VALUE_ACCOUNT_SECTRANSFER_NONE, CONFIG_VALUE_ACCOUNT_SECTRANSFER_SSL, CONFIG_VALUE_ACCOUNT_SECTRANSFER_TLS)

Definition at line 205 of file accountsetupitem.cpp.

int AccountSetupItem::getTransferSecurity (  )  const

Returns the transfer security.

seee constants.h for valid values (CONFIG_VALUE_ACCOUNT_SECTRANSFER_...)

Returns:
transfer security

Definition at line 213 of file accountsetupitem.cpp.

void AccountSetupItem::save (  )  const

Saves this account into applications config.

All values are placed in a group called like the account name.

Definition at line 151 of file accountsetupitem.cpp.

void AccountSetupItem::setUnsecureLoginAllowed ( bool  allowed  ) 

Sets whether an unsecure login is allowed.

Parameters:
allowed TRUE - unsecure login is allowd

Definition at line 261 of file accountsetupitem.cpp.

bool AccountSetupItem::getUnsecureLoginAllowed (  )  const

Return whether an unsecure login is allowed.

Returns:
TRUE - unsecure login is allowed

Definition at line 266 of file accountsetupitem.cpp.


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

Generated on Tue May 18 19:43:53 2010 for KShowmail by  doxygen 1.5.6