EXPORT_C TInt CMsvTestUtils::AppendScheduleTimeL(TMsvId aEntryId, TDes& rOutput)
	{
	TTime entryTime, schTime;
	TTaskInfo info;
	TInt err = ScheduleTime(aEntryId, entryTime, schTime, info);

	if (!err)
		{
		TBuf<128> dateString;

		entryTime.FormatL(dateString, _L("\tEntry: %D%M%Y%/0%1%/1%2%/2%3%/3 %-B%:0%J%:1%T%:2%S%.%*C4%:3%+B"));
		rOutput.Append(dateString);

		schTime.FormatL(dateString, _L("\n\tSched: %D%M%Y%/0%1%/1%2%/2%3%/3 %-B%:0%J%:1%T%:2%S%.%*C4%:3%+B"));
		rOutput.Append(dateString);

		rOutput.AppendFormat(_L(" (taskId %d)\n"), info.iTaskId);
		}
	else
		{
		rOutput.AppendFormat(_L("\tError %d: Cannot read schedule time for msg %d\n"), err, aEntryId);
		}

	return err;
	}
Example #2
0
bool
StreamUtils::getKey( 
            const String &key, 
            const Mapping &inMap, 
            ScheduleTime &data )
{
    time_t inTime;
    bool result = StreamUtils::getKey( key, inMap, inTime );
    if ( result )
    {
        data = ScheduleTime( inTime );
    }
    else
    {
        data.break_time();
    }

    return result;
}