smf/smfservermodule/smfclient/smfactivityfetcher_p.cpp
author cgandhi
Thu, 05 Aug 2010 16:48:48 +0530
changeset 18 013a02bf2bb0
child 25 a180113055cb
permissions -rw-r--r--
pushing changes for common libs and trace messages
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
18
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
     1
/**
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
     2
 * Copyright (c) 2010 Sasken Communication Technologies Ltd.
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
     3
 * All rights reserved.
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
     4
 * This component and the accompanying materials are made available
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
     5
 * under the terms of the "Eclipse Public License v1.0"
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
     6
 * which accompanies  this distribution, and is available
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
     7
 * at the URL "http://www.eclipse.org/legal/epl-v10.html"
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
     8
 *
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
     9
 * Initial Contributors:
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    10
 * Chandradeep Gandhi, Sasken Communication Technologies Ltd - Initial contribution
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    11
 *
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    12
 * Contributors:
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    13
 * Manasij Roy, Nalina Hariharan
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    14
 * 
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    15
 * Description:
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    16
 * Private Implementation of SmfActivityFetcher
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    17
 * 
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    18
 */
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    19
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    20
#include <QDebug>
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    21
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    22
#include "smfactivityfetcher.h"
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    23
#include "smfactivityfetcher_p.h"
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    24
#ifdef Q_OS_SYMBIAN
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    25
	#include "smfclientsymbian.h"
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    26
#else
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    27
	#include "smfclientqt.h"
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    28
#endif
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    29
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    30
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    31
SmfActivityFetcherPrivate::SmfActivityFetcherPrivate(SmfActivityFetcher *activityFetcher)
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    32
		:m_activityFetcher(activityFetcher)
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    33
	{
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    34
#ifdef Q_OS_SYMBIAN
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    35
	//private impl for symbian
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    36
	m_SmfClientPrivate = CSmfClientSymbian::NewL(this);
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    37
#else
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    38
	//TODO:- Qt private impl
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    39
#endif
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    40
	}
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    41
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    42
SmfActivityFetcherPrivate::~SmfActivityFetcherPrivate()
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    43
	{
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    44
	if(m_SmfClientPrivate)
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    45
		{
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    46
		delete m_SmfClientPrivate;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    47
		m_SmfClientPrivate = NULL;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    48
		}
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    49
	}
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    50
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    51
void SmfActivityFetcherPrivate::selfActivities(int pageNum, int perPage)
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    52
	{
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    53
	SmfProvider* m_baseProvider = m_activityFetcher->getProvider();
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    54
	//serialize start
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    55
	m_serializedDataToServer.clear();
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    56
	QDataStream write(&m_serializedDataToServer,QIODevice::WriteOnly);
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    57
	//SmfProvider
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    58
	write<<*m_baseProvider;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    59
	m_argFlag = 1;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    60
	write<<m_argFlag;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    61
	write<<pageNum;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    62
	write<<m_argFlag;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    63
	write<<perPage;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    64
	//serialize end
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    65
	
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    66
	QString intfName(activityFetcherInterface);
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    67
	int max = MaxSmfActivityEntrySize*perPage;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    68
	
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    69
	//call private impl's send method
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    70
	m_SmfClientPrivate->sendRequest(m_serializedDataToServer, intfName,
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    71
			SmfActivitySelfActivity, max);
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    72
	}
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    73
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    74
void SmfActivityFetcherPrivate::friendsActivities(const SmfContact & aFriend, int pageNum, int perPage)
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    75
	{
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    76
	SmfProvider* m_baseProvider = m_activityFetcher->getProvider();
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    77
	//serialize start
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    78
	m_serializedDataToServer.clear();
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    79
	QDataStream write(&m_serializedDataToServer,QIODevice::WriteOnly);
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    80
	//SmfProvider
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    81
	write<<*m_baseProvider;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    82
	m_argFlag = 1;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    83
	write<<m_argFlag;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    84
	write<<aFriend;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    85
	write<<m_argFlag;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    86
	write<<pageNum;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    87
	write<<m_argFlag;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    88
	write<<perPage;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    89
	
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    90
	QString intfName(activityFetcherInterface);
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    91
	int max = MaxSmfActivityEntrySize*perPage;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    92
	
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    93
	//call private impl's send method
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    94
	m_SmfClientPrivate->sendRequest(m_serializedDataToServer, intfName,
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    95
			SmfActivityFriendsActivities, max);
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    96
	}
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    97
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    98
void SmfActivityFetcherPrivate::filtered(QList<SmfActivityObjectType> filters, int pageNum, int perPage)
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
    99
	{
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   100
	SmfProvider* m_baseProvider = m_activityFetcher->getProvider();
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   101
	
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   102
	//serialize start
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   103
	m_serializedDataToServer.clear();
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   104
	QDataStream write(&m_serializedDataToServer,QIODevice::WriteOnly);
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   105
	//SmfProvider
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   106
	write<<*m_baseProvider;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   107
	m_argFlag = 1;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   108
	write<<m_argFlag;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   109
	write<<filters;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   110
	write<<m_argFlag;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   111
	write<<pageNum;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   112
	write<<m_argFlag;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   113
	write<<perPage;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   114
	
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   115
	QString intfName(activityFetcherInterface);
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   116
	int max = MaxSmfActivityEntrySize*perPage;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   117
	
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   118
	//call private impl's send method
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   119
	m_SmfClientPrivate->sendRequest(m_serializedDataToServer, intfName,
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   120
			SmfActivityFiltered, max);
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   121
	}
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   122
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   123
void SmfActivityFetcherPrivate::customRequest ( const int& operationId, QByteArray* customData )
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   124
	{
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   125
	SmfProvider* m_baseProvider = m_activityFetcher->getProvider();
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   126
	
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   127
	//serialize start
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   128
	m_serializedDataToServer.clear();
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   129
	QDataStream write(&m_serializedDataToServer,QIODevice::WriteOnly);
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   130
	write<<*m_baseProvider;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   131
	m_argFlag = 1;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   132
	write<<operationId;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   133
	if(customData)
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   134
		{
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   135
		write<<m_argFlag;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   136
		write<<*customData;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   137
		}
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   138
	else
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   139
		{
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   140
		m_argFlag = 0;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   141
		write<<m_argFlag;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   142
		}
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   143
	
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   144
	QString intfName(activityFetcherInterface);
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   145
//ToDo:- How much size to allocate for custom data? keeping MaxSmfActivityEntrySize for now
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   146
	int maxAllocation = MaxSmfActivityEntrySize;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   147
	
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   148
	//call private impl's send method
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   149
	m_SmfClientPrivate->sendRequest(m_serializedDataToServer, intfName,
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   150
			SmfActivityCustomRequest, maxAllocation);
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   151
	}
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   152
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   153
void SmfActivityFetcherPrivate::resultsAvailable(QByteArray result,SmfRequestTypeID opcode, SmfError error)
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   154
	{
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   155
	qDebug()<<"SmfActivityFetcherPrivate::resultsAvailable";
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   156
	qDebug()<<"opcode = "<<opcode;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   157
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   158
	QDataStream reader(&result,QIODevice::ReadOnly);
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   159
	
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   160
	//Now de-serialize it based on opcode
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   161
	switch(opcode)
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   162
		{
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   163
		case SmfActivitySelfActivity:
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   164
		case SmfActivityFriendsActivities:
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   165
		case SmfActivityFiltered:
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   166
			{
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   167
			SmfActivityEntryList* m_entries = new SmfActivityEntryList;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   168
			reader>>*m_entries;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   169
			qDebug()<<"m_entries.count = "<<m_entries->count();
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   170
			
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   171
			//ToDo:- not incorporating paging now
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   172
			SmfResultPage page;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   173
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   174
			emit m_activityFetcher->resultsAvailable(m_entries,error,page);
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   175
			}
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   176
			break;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   177
			
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   178
   		case SmfActivityCustomRequest:
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   179
   			{
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   180
   			int operationId;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   181
   			QByteArray *data = new QByteArray;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   182
   			reader>>operationId;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   183
   			reader>>*data;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   184
   			
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   185
   			qDebug()<<"operationId = "<<operationId;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   186
   			qDebug()<<"data size = "<<data->size();
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   187
   			emit m_activityFetcher->customDataAvailable(operationId, data);
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   188
   			}
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   189
   			break;
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   190
		default:
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   191
			Q_ASSERT_X(1,"Activity Private Unknown opcode","default case");
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   192
		}
013a02bf2bb0 pushing changes for common libs and trace messages
cgandhi
parents:
diff changeset
   193
	}