telephonyserver/etelmultimode/CETEL/mm_messaging.cpp
branchopencode
changeset 24 6638e7f4bd8f
parent 0 3553901f7fa8
child 77 930a53cdc2d3
equal deleted inserted replaced
23:6b1d113cdff3 24:6638e7f4bd8f
  1074 	iExtensionId=KETelExtMultimodeV1;
  1074 	iExtensionId=KETelExtMultimodeV1;
  1075 	}
  1075 	}
  1076 
  1076 
  1077 EXPORT_C void RMobileUssdMessaging::ReceiveMessage(TRequestStatus& aReqStatus, TDes8& aMsgData, TDes8& aMsgAttributes) const
  1077 EXPORT_C void RMobileUssdMessaging::ReceiveMessage(TRequestStatus& aReqStatus, TDes8& aMsgData, TDes8& aMsgAttributes) const
  1078 /**
  1078 /**
  1079 	This member function enables the client to receive the next incoming USSD message 
  1079 	This member function enables the client to declare an interest in receiving the next 
  1080 	from the network. The request will be completed when a new message arrives.
  1080 	incoming USSD message from the network. The request will be completed when the message is
       
  1081 	offered to the client. The client must then decide to either accept or reject the USSD
       
  1082 	session/dialogue.
  1081 	
  1083 	
  1082 	Use RTelSubSessionBase::CancelAsyncRequest(EMobileUssdMessagingReceiveMessage) 
  1084 	Use RTelSubSessionBase::CancelAsyncRequest(EMobileUssdMessagingReceiveMessage) 
  1083 	to cancel a previously placed asynchronous ReceiveMessage() request.
  1085 	to cancel a previously placed asynchronous ReceiveMessage() request.
  1084 	
  1086 	
  1085 	@param aReqStatus On return, KErrNone if successful.
  1087 	@param aReqStatus On return, KErrNone if successful.
  1088 	the clients are provided with a typedef called RMobileUssdMessaging::TGsmUssdMessageData.
  1090 	the clients are provided with a typedef called RMobileUssdMessaging::TGsmUssdMessageData.
  1089 	@param aMsgAttributes On completion, the TMobileUssdAttributesV1Pckg with the 
  1091 	@param aMsgAttributes On completion, the TMobileUssdAttributesV1Pckg with the 
  1090 	message attributes.
  1092 	message attributes.
  1091  
  1093  
  1092 	@see TMobileUssdAttributesV1
  1094 	@see TMobileUssdAttributesV1
       
  1095 	@see AcceptIncomingDialogue RejectIncomingDialogue
  1093 
  1096 
  1094 @capability ReadDeviceData
  1097 @capability ReadDeviceData
  1095 @capability NetworkControl
  1098 @capability NetworkControl
  1096 */
  1099 */
  1097 	{
  1100 	{
  1098 	Get(EMobileUssdMessagingReceiveMessage, aReqStatus, aMsgData, aMsgAttributes);
  1101 	Get(EMobileUssdMessagingReceiveMessage, aReqStatus, aMsgData, aMsgAttributes);
  1099 	}
  1102 	}
       
  1103 
       
  1104 EXPORT_C TInt RMobileUssdMessaging::AcceptIncomingDialogue() const
       
  1105 /**
       
  1106 	This member function enables the client to accept an incoming USSD message
       
  1107 	and thereby the rest of the session/dialogue with the network. 
       
  1108 	
       
  1109 	It would be called when ReceiveMessage has completed and the client is not 
       
  1110 	currently in a dialogue/session. The alternative would be to call RejectIncomingDialogue
       
  1111 	if the client was not interested in the dialogue (after examining the message data)
       
  1112 	
       
  1113 	If the client calls this function within the time limit allowed 
       
  1114 	further network USSD messages will be sent to this client only. And
       
  1115 	the client can use SendMessage to send USSD messages. This will continue until the session 
       
  1116 	is terminated or there is a session timeout.
       
  1117 	
       
  1118 	@return KErrTimedOut if exceeded allocated time period fir accepting/rejecting. Else KErrNone.
       
  1119 	
       
  1120 	@see ReceiveMessage
       
  1121 	@see RejectIncomingDialogue
       
  1122 	
       
  1123 @capability ReadUserData
       
  1124 @capability NetworkControl
       
  1125 */
       
  1126 	{
       
  1127     TPckgC<TBool> accept(ETrue);
       
  1128     TPckgC<TInt> type(RTelServer::EUssdType);
       
  1129     return Set(EEtelServerAcceptIncoming, type);
       
  1130     }
       
  1131 
       
  1132 EXPORT_C TInt RMobileUssdMessaging::RejectIncomingDialogue() const
       
  1133 /**
       
  1134 	This member function enables the client to to reject an incoming USSD message.
       
  1135 	This indicates the client (having examined the data) is not interested in
       
  1136 	receiving further messages in this dialogue/session. 
       
  1137 	
       
  1138 	It would be called when ReceiveMessage has completed and the client is not 
       
  1139 	currently in a dialogue/session. The alternative would be to call AcceptIncomingDialogue
       
  1140 	if the client was interested in the dialogue (after examining the message data)
       
  1141 	
       
  1142 	If the client calls this function within the time limit allowed 
       
  1143 	further network USSD messages will be sent to this client only and
       
  1144 	the client can use SendMessage to send USSD messages. 
       
  1145 	This will continue until the session is terminated or there is a session timeout.
       
  1146 	
       
  1147 	@return KErrTimedOut if exceeded allocated time period for accepting/rejecting. Else KErrNone.
       
  1148 	
       
  1149 	@see ReceiveMessage
       
  1150 	@see RejectIncomingDialogue
       
  1151 	
       
  1152 @capability ReadUserData
       
  1153 @capability NetworkControl
       
  1154 */
       
  1155     {
       
  1156     TPckgC<TBool> accept(ETrue);
       
  1157     TPckgC<TInt> type(RTelServer::EUssdType);
       
  1158     return Set(EEtelServerRejectIncoming, type);
       
  1159     }
  1100 
  1160 
  1101 EXPORT_C void RMobileUssdMessaging::SendMessage(TRequestStatus& aReqStatus, const TDesC8& aMsgData, const TDesC8& aMsgAttributes) const
  1161 EXPORT_C void RMobileUssdMessaging::SendMessage(TRequestStatus& aReqStatus, const TDesC8& aMsgData, const TDesC8& aMsgAttributes) const
  1102 /**
  1162 /**
  1103 	This member function sends a USSD message to the network.
  1163 	This member function sends a USSD message to the network.
  1104 
  1164