TConnAutoStartPref Class Reference

#include <comms-infras/esock_params.h>

class TConnAutoStartPref : public Meta::SMetaDataECom

Detailed Description

The connection preference requires that the connection waits until its selected access point is available before starting. The start request does not complete until the connection is fully up.

Without this preference(e.g in the TConnPrefList), if the selected access point is unavailable due to contention or lack of coverage, the RConnection::Start is errored immediately.

TConnAutoStartPref does not aid access point selection. When specified without any other preference in the TConnPrefList, the default access point in the KAfInet tier will be selected.

RConnection conn;
User::LeaveIfError(conn.Open(sockSvr));
CleanupClosePushL(conn);

TConnPrefList* prefs = TConnPrefList::NewL();
CleanupStack::PushL(prefs);
TConnAPPref* APPref = TConnAPPref::NewL(aPara->iAp);
CleanupStack::PushL(APPref);
TConnAutoStartPref autoPref = TConnAutoStartPref::NewL();
CleanupStack::PushL(autoPref);

prefs->AppendL(autoPref);
prefs->AppendL(APPref);

error = conn.Start(pref);

See also: RConnection::Start TConnPrefList

since 9.5

Member Enumeration Documentation

Enum anonymous

EnumeratorValueDescription
EUid0x10285E27
ETypeId3

Member Function Documentation

NewL ( )

TConnAutoStartPref *NewL()[static, inline]