example/clientapi/smf/inc/common/smfcontacts/smfgroup.h
changeset 1 4b1e636e8a71
child 2 86af6c333601
equal deleted inserted replaced
0:5d2360e70d9f 1:4b1e636e8a71
       
     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 "{License}"
       
     6 * which accompanies  this distribution, and is available
       
     7 * at the URL "{LicenseUrl}".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Chandradeep Gandhi, Sasken Communication Technologies Ltd - Initial contribution
       
    11 *
       
    12 * Contributors:
       
    13 * Manasij Roy
       
    14 * Description:
       
    15 * Interface spefication for smf service provider
       
    16 *
       
    17 */
       
    18 
       
    19 #ifndef SMFGROUP_H_
       
    20 #define SMFGROUP_H_
       
    21 
       
    22 #include "SmfClientGlobal.h"
       
    23 class SmfContact;
       
    24 //List of SmfContacts
       
    25 typedef QList<SmfContact> SmfContactList;
       
    26 /**
       
    27  * class for a group in social network 
       
    28  */
       
    29 class SMFCLIENT_EXPORT SmfGroup : public QObject
       
    30 	{
       
    31 	Q_OBJECT
       
    32 public:
       
    33 	
       
    34 	/**
       
    35 	 * Constructs a group with list of contacts
       
    36 	 */
       
    37 	SmfGroup(SmfContactList* list=0);
       
    38 	/**
       
    39 	 *Returns list of members in the group
       
    40 	 *@return list of members 
       
    41 	 */
       
    42 	SmfContactList* members()
       
    43 		{
       
    44 		return m_members;
       
    45 		}
       
    46 	
       
    47 	/**
       
    48 	 * Sets the group members
       
    49 	 * @param members list of members to be added to the group 
       
    50 	 */
       
    51 	void setMembers(SmfContactList& members);
       
    52 private:
       
    53 	SmfContactList* m_members;
       
    54 	};
       
    55 /**
       
    56  * Externalization
       
    57  */
       
    58 QDataStream &operator<<(QDataStream &, const SmfGroup &);
       
    59 /**
       
    60  * Internalization
       
    61  */
       
    62 QDataStream &operator>>(QDataStream &, SmfGroup &);
       
    63 #endif /* SMFGROUP_H_ */