2047 CreateSelfReplyData( aMessage ); |
2047 CreateSelfReplyData( aMessage ); |
2048 CleanupStack::PopAndDestroy(); |
2048 CleanupStack::PopAndDestroy(); |
2049 TRACE_FUNC_EXIT |
2049 TRACE_FUNC_EXIT |
2050 return; |
2050 return; |
2051 } |
2051 } |
2052 TATExtEntrySupport entrySupport( aAtCmdFull, |
2052 TATExtEntrySupport entrySupport( aAtCmdFull, aMessage, support ); |
2053 const_cast<RMessage2&>(aMessage), |
|
2054 support ); |
|
2055 TInt i; |
2053 TInt i; |
2056 aComplInfo.iProcessed = EFalse; |
2054 aComplInfo.iProcessed = EFalse; |
2057 TInt count = support->Count(); |
2055 TInt count = support->Count(); |
2058 for ( i=0; i<count; i++ ) |
2056 for ( i=0; i<count; i++ ) |
2059 { |
2057 { |
2141 // If HandleCommand() is implemented synchronously, the command must be |
2139 // If HandleCommand() is implemented synchronously, the command must be |
2142 // saved before executing as CompleteCommandMessage() closes the string |
2140 // saved before executing as CompleteCommandMessage() closes the string |
2143 HBufC8* atCmdFull = HBufC8::NewMaxLC( aEntrySupport.iAtCmdFull.Length() ); |
2141 HBufC8* atCmdFull = HBufC8::NewMaxLC( aEntrySupport.iAtCmdFull.Length() ); |
2144 TPtr8 atCmdFullPtr = atCmdFull->Des(); |
2142 TPtr8 atCmdFullPtr = atCmdFull->Des(); |
2145 atCmdFullPtr.Copy( aEntrySupport.iAtCmdFull ); |
2143 atCmdFullPtr.Copy( aEntrySupport.iAtCmdFull ); |
2146 // First send the entry to the observers |
|
2147 TATExtEntrySupport handleCommandEntry = aEntrySupport; |
|
2148 aEntrySupport.iStartIndex = aStartIndex; |
|
2149 SendToMultipleObserverL( aEntrySupport, atCmdFull ); |
|
2150 aEntrySupport = handleCommandEntry; |
|
2151 // Now execute the HandleCommand() |
2144 // Now execute the HandleCommand() |
2152 iCmdData.iReplyExpected = ETrue; // Set before HandleCommandL() |
2145 iCmdData.iReplyExpected = ETrue; // Set before HandleCommandL() |
2153 HandleCommandL( aEntrySupport, ETrue ); |
2146 HandleCommandL( aEntrySupport, ETrue ); |
|
2147 aEntrySupport.iStartIndex = aStartIndex; |
|
2148 SendToMultipleObserverL( aEntrySupport, atCmdFull ); |
2154 CleanupStack::PopAndDestroy( atCmdFull ); |
2149 CleanupStack::PopAndDestroy( atCmdFull ); |
2155 aReplyExpected = ETrue; |
2150 aReplyExpected = ETrue; |
2156 TRACE_FUNC_EXIT |
2151 TRACE_FUNC_EXIT |
2157 return ETrue; |
2152 return ETrue; |
2158 } |
2153 } |
2190 // saved before executing as CompleteCommandMessage() closes the string |
2185 // saved before executing as CompleteCommandMessage() closes the string |
2191 HBufC8* atCmdFull = HBufC8::NewMaxLC( aEntrySupport.iAtCmdFull.Length() ); |
2186 HBufC8* atCmdFull = HBufC8::NewMaxLC( aEntrySupport.iAtCmdFull.Length() ); |
2192 TPtr8 atCmdFullPtr = atCmdFull->Des(); |
2187 TPtr8 atCmdFullPtr = atCmdFull->Des(); |
2193 atCmdFullPtr.Copy( aEntrySupport.iAtCmdFull ); |
2188 atCmdFullPtr.Copy( aEntrySupport.iAtCmdFull ); |
2194 // Now execute the HandleCommand() |
2189 // Now execute the HandleCommand() |
|
2190 HandleCommandL( aEntrySupport, EFalse ); |
2195 SendToMultipleObserverL( nextSupport, atCmdFull ); |
2191 SendToMultipleObserverL( nextSupport, atCmdFull ); |
2196 HandleCommandL( aEntrySupport, EFalse ); |
|
2197 CleanupStack::PopAndDestroy( atCmdFull ); |
2192 CleanupStack::PopAndDestroy( atCmdFull ); |
2198 } |
2193 } |
2199 else |
2194 else |
2200 { |
2195 { |
2201 // No entry found; send one with reply request |
2196 // No entry found; send one with reply request |
2730 } |
2725 } |
2731 } |
2726 } |
2732 TRACE_FUNC_EXIT |
2727 TRACE_FUNC_EXIT |
2733 return KErrNone; |
2728 return KErrNone; |
2734 } |
2729 } |
2735 |
|
2736 // --------------------------------------------------------------------------- |
|
2737 // Assignment operator for ease of usage |
|
2738 // --------------------------------------------------------------------------- |
|
2739 // |
|
2740 TATExtEntrySupport& TATExtEntrySupport::operator=( TATExtEntrySupport& aEntrySupport ) |
|
2741 { |
|
2742 if ( &aEntrySupport == this ) |
|
2743 { |
|
2744 return aEntrySupport; |
|
2745 } |
|
2746 iAtCmdFull = aEntrySupport.iAtCmdFull; |
|
2747 iMessage = aEntrySupport.iMessage; |
|
2748 iSupport = aEntrySupport.iSupport; |
|
2749 iEntry = aEntrySupport.iEntry; |
|
2750 iStartIndex = aEntrySupport.iStartIndex; |
|
2751 iSupportFound = aEntrySupport.iSupportFound; |
|
2752 return *this; |
|
2753 } |
|