List of all members | Signals | Public Member Functions | Static Public Member Functions
QtDcmPreferences Class Reference

Class that manages the settings of QtDcm. More...

#include <QtDcmPreferences.h>

Inherits QObject.

Signals

void preferencesUpdated ()
 

Public Member Functions

void readSettings ()
 Read the settings from the ini file. More...
 
void writeSettings ()
 Store current settings in the ini file. More...
 
void setIniFile (const QString ini)
 
QString iniFile (void)
 
QString aetitle () const
 QtDcm local AETitle getter. More...
 
QString port () const
 QtDcm local application TCP port getter. More...
 
QList< QtDcmServerservers () const
 QtDcm server list getter. More...
 
void setHostname (const QString &hostname)
 QtDcm local AETitle setter. More...
 
QString hostname () const
 
void setAetitle (const QString &aetitle)
 QtDcm local AETitle setter. More...
 
void setPort (const QString &port)
 QtDcm local application TCP port setter. More...
 
QString dcm2niiPath () const
 
void setDcm2niiPath (const QString &path)
 
bool useDcm2nii () const
 
void setUseDcm2nii (bool use)
 
void addServer (const QtDcmServer &server)
 Add server to the QList. More...
 
void removeServer (int index)
 Remove server from the QList at position i. More...
 
void setServers (const QList< QtDcmServer > &servers)
 QtDcm server list setter. More...
 

Static Public Member Functions

static QtDcmPreferencesinstance ()
 
static void destroy ()
 

Detailed Description

Class that manages the settings of QtDcm.

The Settings are organized like this :
[LocalSettings]
AETitle=""
Port=""
Encoding=""

[Servers]
Server1\AETitle=""
Server1\Hostname=""
Server1\Port=""
Server1\Name=""
...

Todo:
Add path to dcm2nii and dcm4che in the preferences

Definition at line 50 of file QtDcmPreferences.h.

Member Function Documentation

QtDcmPreferences * QtDcmPreferences::instance ( )
static

Definition at line 51 of file QtDcmPreferences.cpp.

void QtDcmPreferences::destroy ( )
static

Definition at line 60 of file QtDcmPreferences.cpp.

void QtDcmPreferences::readSettings ( )

Read the settings from the ini file.

This method use the QSettings object and initialize the private attributes with the content of the ini file.

Definition at line 78 of file QtDcmPreferences.cpp.

void QtDcmPreferences::writeSettings ( )

Store current settings in the ini file.

This method use the QSettings object to store the current settings in the ini file.

Definition at line 114 of file QtDcmPreferences.cpp.

void QtDcmPreferences::setIniFile ( const QString  ini)

Definition at line 173 of file QtDcmPreferences.cpp.

QString QtDcmPreferences::iniFile ( void  )

Definition at line 168 of file QtDcmPreferences.cpp.

QString QtDcmPreferences::aetitle ( ) const

QtDcm local AETitle getter.

Returns
_aetitle as a QString

Definition at line 194 of file QtDcmPreferences.cpp.

QString QtDcmPreferences::port ( ) const

QtDcm local application TCP port getter.

Returns
_port as a QString

Definition at line 199 of file QtDcmPreferences.cpp.

QList< QtDcmServer > QtDcmPreferences::servers ( ) const

QtDcm server list getter.

Returns
_servers as a QList of server
See also
QtDcmServer

Definition at line 204 of file QtDcmPreferences.cpp.

void QtDcmPreferences::setHostname ( const QString &  hostname)

QtDcm local AETitle setter.

Parameters
hostnameas a QString

Definition at line 209 of file QtDcmPreferences.cpp.

QString QtDcmPreferences::hostname ( ) const

Definition at line 214 of file QtDcmPreferences.cpp.

void QtDcmPreferences::setAetitle ( const QString &  aetitle)

QtDcm local AETitle setter.

Parameters
aetitleas a QString

Definition at line 219 of file QtDcmPreferences.cpp.

void QtDcmPreferences::setPort ( const QString &  port)

QtDcm local application TCP port setter.

Parameters
portas a QString

Definition at line 224 of file QtDcmPreferences.cpp.

QString QtDcmPreferences::dcm2niiPath ( ) const

Definition at line 234 of file QtDcmPreferences.cpp.

void QtDcmPreferences::setDcm2niiPath ( const QString &  path)

Definition at line 239 of file QtDcmPreferences.cpp.

bool QtDcmPreferences::useDcm2nii ( ) const

Definition at line 244 of file QtDcmPreferences.cpp.

void QtDcmPreferences::setUseDcm2nii ( bool  use)

Definition at line 249 of file QtDcmPreferences.cpp.

void QtDcmPreferences::addServer ( const QtDcmServer server)

Add server to the QList.

Definition at line 68 of file QtDcmPreferences.cpp.

void QtDcmPreferences::removeServer ( int  index)

Remove server from the QList at position i.

Parameters
indexof the server to be removed in the list

Definition at line 73 of file QtDcmPreferences.cpp.

void QtDcmPreferences::setServers ( const QList< QtDcmServer > &  servers)

QtDcm server list setter.

Parameters
serversas a QList of servers
See also
QtDcmServer

Definition at line 229 of file QtDcmPreferences.cpp.

void QtDcmPreferences::preferencesUpdated ( )
signal

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