CStifItemParser Class Reference

class CStifItemParser : public CBase

Inherits from

Constructor & Destructor Documentation

CStifItemParser(TPtrC, TInt, TInt)

CStifItemParser(TPtrCaSection,
TIntaStartPos,
TIntaLength
)[private]

C++ default constructor.

Parameters

TPtrC aSection
TInt aStartPos
TInt aLength

~CStifItemParser()

~CStifItemParser()

Destructor.

Member Functions Documentation

ConstructL()

voidConstructL()[private]

By default Symbian OS constructor is private.

GetChar(const TDesC &, TChar &)

IMPORT_C TIntGetChar(const TDesC &aTag,
TChar &aCharacter
)

Get a character with a tag. Returns an error code and a reference to the parsed character. If start tag is empty the first character will be parsed and returned.

Parameters

const TDesC & aTag
TChar & aCharacter

GetInt(const TDesC &, TInt &)

IMPORT_C TIntGetInt(const TDesC &aTag,
TInt &aInteger
)

Get a integer(TInt) with a tag. Returns an error code and a reference to the parsed integer. If start tag is empty the first integer will be parsed and returned.

Parameters

const TDesC & aTag
TInt & aInteger

GetInt(const TDesC &, TUint &, TRadix)

IMPORT_C TIntGetInt(const TDesC &aTag,
TUint &aInteger,
TRadixaRadix = EDecimal
)

Get a integer(TUint) with a tag. Returns an error code and a reference to the parsed integer. If start tag is empty the first integer will be parsed and returned. With TRadix parameter can convert a number into different presentation(EBinary, EOctal, EDecimal and EHex).

Parameters

const TDesC & aTag
TUint & aInteger
TRadix aRadix = EDecimal

GetNextChar(TChar &)

IMPORT_C TIntGetNextChar(TChar &aCharacter)

Get next character. Returns an error code and a reference to the parsed character. GetString or GetInt or GetChar must be called before call GetNextChar method.

Parameters

TChar & aCharacter

GetNextChar(const TDesC &, TChar &)

IMPORT_C TIntGetNextChar(const TDesC &aTag,
TChar &aCharacter
)

Get next character with a tag. Returns an error code and a reference to the parsed character. If start tag is empty the next character will be parsed and returned. GetString or GetInt or GetChar must be called before call GetNextChar method.

Parameters

const TDesC & aTag
TChar & aCharacter

GetNextInt(TInt &)

IMPORT_C TIntGetNextInt(TInt &aInteger)

Get next integer(TInt). Returns an error code and a reference to the parsed integer. GetString or GetInt or GetChar must be called before call GetNextInt method.

Parameters

TInt & aInteger

GetNextInt(const TDesC &, TInt &)

IMPORT_C TIntGetNextInt(const TDesC &aTag,
TInt &aInteger
)

Get next integer(TInt) with a tag. Returns an error code and a reference to the parsed integer. If start tag is empty the next integer will be parsed and returned. GetString or GetInt or GetChar must be called before call GetNextInt method.

Parameters

const TDesC & aTag
TInt & aInteger

GetNextInt(TUint &, TRadix)

IMPORT_C TIntGetNextInt(TUint &aInteger,
TRadixaRadix = EDecimal
)

Get next integer(TUint). Returns an error code and a reference to the parsed integer. GetString or GetInt or GetChar must be called before call GetNextInt method. With TRadix parameter can convert a number into different presentation(EBinary, EOctal, EDecimal and EHex).

Parameters

TUint & aInteger
TRadix aRadix = EDecimal

GetNextInt(const TDesC &, TUint &, TRadix)

IMPORT_C TIntGetNextInt(const TDesC &aTag,
TUint &aInteger,
TRadixaRadix = EDecimal
)

Get next integer(TUint) with a tag. Returns an error code and a reference to the parsed integer. If start tag is empty the next integer will be parsed and returned. GetString or GetInt or GetChar must be called before call GetNextInt method. With TRadix parameter can convert a number into different presentation(EBinary, EOctal, EDecimal and EHex).

Parameters

const TDesC & aTag
TUint & aInteger
TRadix aRadix = EDecimal

GetNextString(TPtrC &)

IMPORT_C TIntGetNextString(TPtrC &aString)

Get next string. Returns an error code and a reference to the parsed string. GetString or GetInt or GetChar must be called before call GetNextString method.

Parameters

TPtrC & aString

GetNextString(const TDesC &, TPtrC &)

IMPORT_C TIntGetNextString(const TDesC &aTag,
TPtrC &aString
)

Get next string with a tag. Returns an error code and a reference to the parsed string. If start tag is empty the next string will be parsed and returned. GetString or GetInt or GetChar must be called before call GetNextString method.

Parameters

const TDesC & aTag
TPtrC & aString

GetString(const TDesC &, TPtrC &)

IMPORT_C TIntGetString(const TDesC &aTag,
TPtrC &aString
)

Get a string with a tag. Returns an error code and a reference to the parsed string. If start tag is empty the first string will be parsed and returned.

Parameters

const TDesC & aTag
TPtrC & aString

NewL(TPtrC, TInt, TInt)

IMPORT_C CStifItemParser *NewL(TPtrCaSection,
TIntaStartPos,
TIntaLength
)[static]

Two-phased constructor.

Parameters

TPtrC aSection
TInt aStartPos
TInt aLength

ParseStartAndEndPos(TPtrC, const TDesC &, TInt &, TInt &, TInt &, TInt &)

TInt ParseStartAndEndPos(TPtrCaSection,
const TDesC &aStartTag,
TInt &aStartPos,
TInt &aEndPos,
TInt &aLength,
TInt &aExtraEndPos
)[private]

Generig start and end position parser for given data. Returns an error code.

Parameters

TPtrC aSection
const TDesC & aStartTag
TInt & aStartPos
TInt & aEndPos
TInt & aLength
TInt & aExtraEndPos

ParsingType()

IMPORT_C CStifItemParser::TParsingTypeParsingType()

Get current parsing type. Please see TParsingType enumeration for more inforamtion.

Remainder(TPtrC &)

IMPORT_C TIntRemainder(TPtrC &aString)

Get remaining strings. Returns an error code and a reference to the remainder of the parsed line. Note: This method does not support the quote(TParsingType) feature, only GetString and GetNextString methods include support.

Parameters

TPtrC & aString

SetParsingType(CStifItemParser::TParsingType)

IMPORT_C TIntSetParsingType(CStifItemParser::TParsingTypeaType)

Parsing type can be given when parsing string(GetString and GetNextString). See TParsingType enumeration for more inforamtion.

Member Enumerations Documentation

Enum TParsingType

Enumerators

ENormalParsing
EQuoteStyleParsing

Member Data Documentation

TBool iGetMethodsIndicator

TBool iGetMethodsIndicator[private]

Indicator is GetString(), GetInt() or GetChar() called.

TPtrC iItemLineSection

TPtrC iItemLineSection[private]

Parsed section with GetItemLineL() or GetNextItemLineL() method.

TInt iItemSkipAndMarkPos

TInt iItemSkipAndMarkPos[private]

Indicates position where start the parsing.

CStifItemParser::TParsingType iParsingType

CStifItemParser::TParsingType iParsingType[private]

Parsing type indicator for GetString and GetNextString use.