CDscItem Class Reference

class CDscItem : public CBase

CDscItem class containing application/process information required by the AMAStarter to launch an AMA. It is inherit from CStartupProperties

When an instance of this class is created it contains default values for all properties.

Inherits from

Constructor & Destructor Documentation

CDscItem()

CDscItem()[private]

~CDscItem()

IMPORT_C~CDscItem()

Member Functions Documentation

Args()

IMPORT_C TPtrCArgs()const

Accessor function returning the args value of the item CStartupProperties

ConstructL()

voidConstructL()[private]

DscId()

IMPORT_C TUidDscId()const

Accessor function returning the DscId of the DSC this item was retrieved from

FileName()

IMPORT_C TPtrCFileName()const

Accessor function returning the filename value of the item CStartupProperties

ItemId()

IMPORT_C TIntItemId()const

Accessor function returning ItemId of the item

Monitored()

IMPORT_C TBoolMonitored()const

Accessor function returning the monitored value of the item CStartupProperties

NewL()

IMPORT_C CDscItem *NewL()[static]
Used to create an instance of the CDscItem class
leave
One of the system-wide error codes

NewL(const TDesC &, const TDesC &)

IMPORT_C CDscItem *NewL(const TDesC &aFileName,
const TDesC &aArgs
)[static]

Parameters

const TDesC & aFileName
const TDesC & aArgs

NewLC()

IMPORT_C CDscItem *NewLC()[static]
Used to create an instance of the CDscItem class. The returned instance is put on the CleanupStack.
leave
One of the system-wide error codes

NewLC(const TDesC &, const TDesC &)

IMPORT_C CDscItem *NewLC(const TDesC &aFileName,
const TDesC &aArgs
)[static]

Parameters

const TDesC & aFileName
const TDesC & aArgs

NoOfRetries()

IMPORT_C TIntNoOfRetries()const

Accessor function returning the number of retries value of the item CStartupProperties

Reset()

IMPORT_C voidReset()

Reset all variables in this instance back to constructor defaults. This will enable to reuse this instance instead of having to delete it and create a new one.

SetDscId(const TUid &)

IMPORT_C voidSetDscId(const TUid &aDscId)

Sets the Id of the Dynamic Startup Configuration list this item resides in. The dscId of a DSC in the database must be set with this method before adding, updating, or deleting this item in this DSC

Parameters

const TUid & aDscIdId of the DSC this item resides in.

SetFileParamsL(const TDesC &, const TDesC &)

IMPORT_C voidSetFileParamsL(const TDesC &aFileName,
const TDesC &aArgs
)
Sets the filename and args values of the item
leave
KErrArgument - the filename is empty or one of the parameters exceeds KDscStoreMaxStringLength
leave
One of the system-wide error codes
CStartupProperties

Parameters

const TDesC & aFileNamefilename of the component.
const TDesC & aArgsarg list of the component.

SetItemId(const TInt)

IMPORT_C voidSetItemId(const TIntaItemId)
Sets itemId parameter for the item. Can only be set once. Normally the itemId is set by the DBMS, but if you know the itemId for a DscItem in the database you can create an empty CDscItem, set the itemId+dscId and let the DBMS look it up and fill in the other values.
panic
if you try to change the value

Parameters

const TInt aItemIdId of the item.

SetMonitored(TBool)

IMPORT_C voidSetMonitored(TBoolaMonitored)

Sets the monitored value of the item CStartupProperties

Parameters

TBool aMonitoredWhether the component is to be monitored once it is started

SetNoOfRetriesL(TInt)

IMPORT_C voidSetNoOfRetriesL(TIntaNumRetries)
Sets the number of retries value of the item
leave
KErrArgument - the number of retries must be either 0 or 1
CStartupProperties

Parameters

TInt aNumRetriesnumber of retries should the start fail

SetStartInBackground(TBool)

IMPORT_C voidSetStartInBackground(TBoolaStartInBackground)

Sets the StartInBackground value of the item CStartupProperties

Parameters

TBool aStartInBackgroundWhether to start the application in the background or not

SetStartMethodL(TStartMethod)

IMPORT_C voidSetStartMethodL(TStartMethodaStartMethod)
Sets the start method value of the item
leave
KErrArgument - the start method is not either EFireAndForget or EWaitForStart
CStartupProperties

Parameters

TStartMethod aStartMethodHow we want to start the component

SetStartupTypeL(TStartupType)

IMPORT_C voidSetStartupTypeL(TStartupTypeaType)

Sets the startup type value of the item CStartupProperties

Parameters

TStartupType aTypeThe startup type

SetTimeoutL(TInt)

IMPORT_C voidSetTimeoutL(TIntaTimeout)
Sets the timeout value of the item
leave
KErrArgument - the timeout must not be negative
CStartupProperties

Parameters

TInt aTimeouttimeout between retries

SetViewless(TBool)

IMPORT_C voidSetViewless(TBoolaViewless)

Sets the viewless value of the item CStartupProperties

Parameters

TBool aViewlessWhether the application is viewless or not

SsmStartupProperties()

IMPORT_C const CSsmStartupProperties &SsmStartupProperties()const

Returns a const reference to the embedded startup properties object CSsmStartupProperties

StartInBackground()

IMPORT_C TBoolStartInBackground()const

Accessor function returning the StartInBackground value of the item CStartupProperties

StartMethod()

IMPORT_C TStartMethodStartMethod()const

Accessor function returning the start method value of the item CStartupProperties

StartupProperties()

IMPORT_C const CStartupProperties &StartupProperties()const

Returns a const reference to the embedded startup properties object CStartupProperties

StartupType()

IMPORT_C TStartupTypeStartupType()const

Accessor function returning the startup type value of the item CStartupProperties

Timeout()

IMPORT_C TIntTimeout()const

Accessor function returning the timeout value of the item CStartupProperties

Viewless()

IMPORT_C TBoolViewless()const

Accessor function returning the viewless value of the item CStartupProperties

Member Data Documentation

TUid iDscId

TUid iDscId[private]

TInt iItemId

TInt iItemId[private]

CSsmStartupProperties * iSsmStartupProperties

CSsmStartupProperties *iSsmStartupProperties[private]

CStartupProperties * iStartupProperties

CStartupProperties *iStartupProperties[private]