1 #ifndef CONNECTION_H_
\r
2 #define CONNECTION_H_
\r
7 //! Domain class. Stores connection information.
\r
9 * Domain class. Stores connection information like server url, username, password and refresh
\r
12 class ConnectionSettings
\r
17 * Overloaded. Constructor to initialize a ConnectionSettings instance.
\r
18 * \param aServerUrl The URL of the Exchange server.
\r
19 * \param aUsername The username used to log in to the server.
\r
20 * \param aPassword The password used to log in to the server.
\r
21 * \param aRefreshInterval The interval defines how often the server's data must be fetched. (Interpreted in seconds.)
\r
23 ConnectionSettings( const QUrl &aServerUrl, const QString &aUsername, const QString &aPassword, unsigned int aRefreshInterval );
\r
24 //! Copy constructor.
\r
26 * Overloaded. Constructor to initialize a ConnectionSettings instance.
\r
27 * \param aOther ConnectionSettings class to be copied.
\r
29 ConnectionSettings( const ConnectionSettings &aOther );
\r
31 virtual ~ConnectionSettings();
\r
33 //! Gets the server address
\r
35 * Gets the server url address.
\r
36 * \return Url address of server.
\r
39 //! Gets the username.
\r
41 * Gets username used to connect.
\r
45 //! Gets the password.
\r
47 * Gets the password used to connect.
\r
51 //! Gets the refresh interval.
\r
53 * Gets refresh interval in seconds to read the data from server.
\r
54 * \return Refresh interval.
\r
56 unsigned int refreshInterval();
\r
58 //! Sets the server address
\r
60 * Sets the server url address.
\r
61 * \param aServerUrl Url address of server.
\r
63 void setServerUrl( const QUrl &aServerUrl );
\r
64 //! Sets the username.
\r
66 * Sets username used to connect.
\r
67 * \param aUsername Username.
\r
69 void setUsername( const QString &aUsername );
\r
70 //! Sets the password.
\r
72 * Sets the password used to connect.
\r
73 * \param aPassword Password.
\r
75 void setPassword( const QString &aPassword );
\r
76 //! Sets the refresh interval.
\r
78 * Sets refresh interval in seconds to read the data from server.
\r
79 * \param aRefreshInterval Refresh interval.
\r
81 void setRefreshInterval( unsigned int aRefreshInterval );
\r
88 unsigned int iRefreshInterval; // in seconds
\r
92 #endif /*CONNECTION_H_*/
\r