Symbian
Symbian OS Library

SYMBIAN OS V9.3

[Index] [Spacer] [Previous] [Next]



Location: SyncMLDataFilter.h
Link against: smlfilter.lib

This item is not part of the S60 3rd Edition SDK for Symbian OS, Feature Pack 2.

Class CSyncMLFilter

class CSyncMLFilter : public CBase;

Description

Class representing a filter. It is created by the Data Provider and then used and modified by others as a copy of the original one - can be a copy comming from the filter directly or from a stream.

Derivation

Members

Defined in CSyncMLFilter:
AddPropertyL(), ClearPropertiesL(), DisplayDescription(), DisplayName(), Enabled(), ExternalizeL(), FilterId(), FilterLevel(), NewL(), NewL(), NewL(), Properties(), PropertyCount(), PropertyL(), SetEnabledL(), UnsetAllPropertyValuesL(), ~CSyncMLFilter()

Inherited from CBase:
Delete(), Extension_(), operator new()


Construction and destruction


NewL()

static IMPORT_C CSyncMLFilter *NewL(const CSyncMLFilter &aFilter);

Description

static Copy Constructor. Create an identical filter (including properties) from an existing object.

Parameters

const CSyncMLFilter &aFilter

The source filter to copy

Return value

CSyncMLFilter *

The copy of the filter object


NewL()

static IMPORT_C CSyncMLFilter *NewL(RReadStream &aStream);

Description

static Symbian constructor taking in a previously externalised object either from a descriptor in RAM or a resource file. Any properties will also be internalised and instantiated.

Parameters

RReadStream &aStream

The externalised stream of bytes containing the information to produce this object

Return value

CSyncMLFilter *

The instantiated version of the externalised source


NewL()

static IMPORT_C CSyncMLFilter *NewL(TSmlFilterId aId, TSyncMLFilterLevelType aFilterLevel, const TDesC &aDisplayName, const TDesC &aDisplayDescription);

Description

Static Symbian constructor producing an instantiated object from constituent parts which make up the minimum.

Parameters

TSmlFilterId aId

A unique identifier used to reference this particular filter

TSyncMLFilterLevelType aFilterLevel

Defines the filter as one that filters whole records or filters the fields

const TDesC &aDisplayName

User friendly display name for UI use

const TDesC &aDisplayDescription

User friendly description of the filter for UI use

Return value

CSyncMLFilter *

The filter object


~CSyncMLFilter()

virtual IMPORT_C ~CSyncMLFilter();

Description

C++ destructtor

[Top]


Member functions


ExternalizeL()

IMPORT_C void ExternalizeL(RWriteStream &aStream) const;

Description

Method to produce an externalised string of bytes from which a CSyncMLFilter object can be recreated from. Used when objects need to be passed across IPC boundaries or stored on disk.

Parameters

RWriteStream &aStream

A stream that the externalised form of this object will append to


FilterId()

IMPORT_C TSmlFilterId FilterId() const;

Description

Accessor returning the unique Id of this filter.

Return value

TSmlFilterId

The unique Id


DisplayName()

IMPORT_C const TDesC &DisplayName() const;

Description

Accessor returning the User friendly display name of this filter.

Return value

const TDesC &

The display name


DisplayDescription()

IMPORT_C const TDesC &DisplayDescription() const;

Description

Accessor returning the User friendly description of this filter.

Return value

const TDesC &

The description


Properties()

IMPORT_C const RPointerArray< CSyncMLFilterProperty > &Properties() const;

Description

Accessor returning the array of properties owned by this filter that define it's behaviour. Note that the array is const and hence any additions to it must be done through the appropriate mutator's such as AddPropertyL().

Return value

const RPointerArray< CSyncMLFilterProperty > &

The property array


SetEnabledL()

IMPORT_C void SetEnabledL(TBool aEnabled);

Description

Enables the filter. Filters can be enabled or disabled depending on whether or not the user wishes them to be applied to the sync or not.

Parameters

TBool aEnabled

Set the filter enabled or disabled

Leave codes

KErrCorrupt

if the user attempts to enable an invalid filter


Enabled()

IMPORT_C TBool Enabled() const;

Description

Accessor indicating the filter's enabled state.

Return value

TBool

Whether or not the filter is enabled


FilterLevel()

IMPORT_C TSyncMLFilterLevelType FilterLevel() const;

Description

Indicates whether the filter is a field or record level filter.

Return value

TSyncMLFilterLevelType

Level of filter (field or record)


ClearPropertiesL()

IMPORT_C void ClearPropertiesL();

Description

Deletes all properties owned by this filter. This method must only be used at initial filter construction time in the data provider and should not be used from the User Interface code.


AddPropertyL()

IMPORT_C void AddPropertyL(CSyncMLFilterProperty *aProperty);

Description

Passes ownership of a filter property object to this filter. The property isn't necessarily enabled. This method must only be used at initial filter construction time in the data provider and should not be used from the User Interface code.

Parameters

CSyncMLFilterProperty *aProperty

The CSyncMLFilterProperty object that ownership is being passed for

Leave codes

KErrArgument

on a NULL pointer


PropertyCount()

IMPORT_C TInt PropertyCount() const;

Description

Returns the number of properties that this filter owns.

Return value

TInt

The number of properties owned by this filter


PropertyL()

IMPORT_C CSyncMLFilterProperty &PropertyL(TInt aIndex) const;

Description

Return a reference to a particular property in the field's property array.

Parameters

TInt aIndex

Index of the CSyncMLFilterProperty object that a reference is requested for

Return value

CSyncMLFilterProperty &

Reference to the CSyncMLFilterProperty object at index aIndex

Leave codes

KErrNotFound

If the index number is out of bounds


UnsetAllPropertyValuesL()

IMPORT_C void UnsetAllPropertyValuesL();

Description

Unsets all properties that may have previously been configured with values