EXPORT_C void CExampleCookieManager::GetCookiesL(RHTTPTransaction aTransaction, 
												 RArray<CCookie*>& aCookieList,
												 TBool& aCookie2Reqd)
	{
	// For comparing cookies to insert them in the correct order to the returned array
	TLinearOrder<CCookie*> compareFunc(CompareCookiePaths);

	// Ensure the array is empty
	__ASSERT_DEBUG(aCookieList.Count()==0, HTTPCookiePanic::Panic(HTTPCookiePanic::EGetCookiesArrayNotEmpty));

	const TInt numCookies = iCookies.Count();
	for (TInt ii=0; ii<numCookies; ++ii)
		{
		CCookie* cookie = iCookies[ii];
		const TUriC8& uri = aTransaction.Request().URI();

		if(CheckDomainMatch(*cookie, uri) &&
		   CheckPathMatch(*cookie, uri) &&
		   CheckPortMatch(*cookie, uri) &&
		   CheckSecureMatch(*cookie, uri))
			{
			User::LeaveIfError(aCookieList.InsertInOrderAllowRepeats(cookie, compareFunc));

			if(!cookie->FromCookie2())
				aCookie2Reqd = ETrue;
			}
		}
	}
void CMemoryView::HandleNewChunk(const TDesC& aName, TUint32 aAddress, TInt aMaxSize)
{
    // Age all the existing chunk's update counts by one.
    const TInt numChunks = iChunkList.Count();
    for (TInt i = 0; i < numChunks; ++i)
    {
        ++iChunkList[i].iUpdateCount;
    }

    // Insert the new chunk (claiming update count zero).
    TChunkInfo newChunkInfo(aName, aAddress, aMaxSize);
    TInt err = iChunkList.InsertInOrderAllowRepeats(newChunkInfo, *iCurrentSortType);
    if (err)
    {
        PrintWarning(_L("Couldn't handle new chunk: %d"), err);
    }
}