Namespaces
Variants
Actions

Alarm Clock One API

Jump to: navigation, search
Article Metadata

Code Example
Article
Created: kiran.mudiyam (06 Jun 2008)
Last edited: hamishwillee (19 Jul 2012)
Note.png
Note: :This API is not part of the public SDK. It can be found in the SDK API Plug-in.

Contents

APIPurpose

KAlarmClockOne can be used to identify whether an alarm in the alarm server is a clock alarm or not. A client-side API for the alarm server is RASCliSession.

MMP files.

Add following libraries.

LIBRARY alarmshared.lib alarmclient.lib


Header file.

Include following header files.

#include <almconst.h>
#include <ASShdAlarm.h>
#include <ASCliSession.h>

Use cases

It can be used to find out if an alarm is a clock alarm or not.

Example code

RArray<TAlarmId> ids;
//iCliSession is of type RASCliSession.
iCliSession.GetAlarmIdListL(ids);
TASShdAlarm alarm;
for(TInt i = 0; i<ids.Count();i++)
{
TInt err ( KErrNone );
err = iCliSession.GetAlarmDetails( ids[i], alarm );
if( (!err))
{
// Check if alarm is clock alarm or not.KAlarmClockOne stands for clock alarm
if ( alarm.Category().iUid == KAlarmClockOne.iUid )
{
CEikonEnv::InfoWinL(_L("Clock Alarm"),alarm.Message());
}
else
{
CEikonEnv::InfoWinL(_L("Not Clock Alarm"),alarm.Message());
}
}
}

Example Application

File:AlarmNotification.zip

 
Nokia Developer aims to help you create apps and publish them so you can connect with users around the world.

京ICP备05048969号  © Copyright Nokia 2013 All rights reserved