18
|
1 |
/**
|
|
2 |
* Copyright (c) 2010 Sasken Communication Technologies Ltd.
|
|
3 |
* All rights reserved.
|
|
4 |
* This component and the accompanying materials are made available
|
|
5 |
* under the terms of the "Eclipse Public License v1.0"
|
|
6 |
* which accompanies this distribution, and is available
|
|
7 |
* at the URL "http://www.eclipse.org/legal/epl-v10.html"
|
|
8 |
*
|
|
9 |
* Initial Contributors:
|
|
10 |
* Chandradeep Gandhi, Sasken Communication Technologies Ltd - Initial contribution
|
|
11 |
*
|
|
12 |
* Contributors:
|
|
13 |
* Manasij Roy, Nalina Hariharan
|
|
14 |
*
|
|
15 |
* Description:
|
|
16 |
* Private class implemented for implicit sharing of SmfPost class
|
|
17 |
*
|
|
18 |
*/
|
|
19 |
|
|
20 |
#ifndef SMFPOST_P_H_
|
|
21 |
#define SMFPOST_P_H_
|
|
22 |
|
|
23 |
#include <QSharedData>
|
|
24 |
#include "smfcontact.h"
|
|
25 |
class SmfPostPrivate : public QSharedData
|
|
26 |
{
|
|
27 |
public:
|
|
28 |
/**
|
|
29 |
* Constructor
|
|
30 |
*/
|
|
31 |
SmfPostPrivate( ) { m_title.clear(); m_desc.clear(); m_url.clear(); m_postId.clear(); }
|
|
32 |
|
|
33 |
/**
|
|
34 |
* Constructor
|
|
35 |
*/
|
|
36 |
SmfPostPrivate(SmfContact aOwner, QString aTitle, QString aDesc, QImage aImage, QUrl aUrl )
|
|
37 |
{
|
|
38 |
m_owner = aOwner;
|
|
39 |
m_title = aTitle;
|
|
40 |
m_desc = aDesc;
|
|
41 |
m_image = aImage;
|
|
42 |
m_url = aUrl;
|
|
43 |
m_postId.clear();
|
|
44 |
}
|
|
45 |
|
|
46 |
/**
|
|
47 |
* Copy Consturctor
|
|
48 |
* @param aOther The reference object to be copy constructed
|
|
49 |
*/
|
|
50 |
SmfPostPrivate( const SmfPostPrivate &aOther ) :
|
|
51 |
QSharedData ( aOther ),
|
|
52 |
m_title ( aOther.m_title ),
|
|
53 |
m_desc ( aOther.m_desc ),
|
|
54 |
m_image ( aOther.m_image ),
|
|
55 |
m_url ( aOther.m_url ),
|
|
56 |
m_date ( aOther.m_date ),
|
|
57 |
m_postId ( aOther.m_postId ) { }
|
|
58 |
|
|
59 |
/**
|
|
60 |
* Destructor
|
|
61 |
*/
|
|
62 |
~SmfPostPrivate( )
|
|
63 |
{
|
|
64 |
}
|
|
65 |
|
|
66 |
SmfContact m_owner; //owner of the post(who posted this message)
|
|
67 |
QString m_title; // title
|
|
68 |
QString m_desc; // description
|
|
69 |
QImage m_image; // image
|
|
70 |
QUrl m_url; // url
|
|
71 |
QDateTime m_date; // posted date
|
|
72 |
QString m_postId; // post's unique Id
|
|
73 |
|
|
74 |
};
|
|
75 |
|
|
76 |
#endif /* SMFPOST_P_H_ */
|