epoc32/include/delimitedpath8.h
author William Roberts <williamr@symbian.org>
Wed, 31 Mar 2010 12:33:34 +0100
branchSymbian3
changeset 4 837f303aceeb
parent 2 2fe1408b6811
permissions -rw-r--r--
Current Symbian^3 public API header files (from PDK 3.0.h)
This is the epoc32/include tree with the "platform" subtrees removed, and
all but a selected few mbg and rsg files removed.
williamr@2
     1
// Copyright (c) 2001-2009 Nokia Corporation and/or its subsidiary(-ies).
williamr@2
     2
// All rights reserved.
williamr@2
     3
// This component and the accompanying materials are made available
williamr@4
     4
// under the terms of "Eclipse Public License v1.0"
williamr@2
     5
// which accompanies this distribution, and is available
williamr@4
     6
// at the URL "http://www.eclipse.org/legal/epl-v10.html".
williamr@2
     7
//
williamr@2
     8
// Initial Contributors:
williamr@2
     9
// Nokia Corporation - initial contribution.
williamr@2
    10
//
williamr@2
    11
// Contributors:
williamr@2
    12
//
williamr@2
    13
// Description:
williamr@2
    14
//
williamr@2
    15
williamr@2
    16
#ifndef __DELIMITEDPATH8_H__
williamr@2
    17
#define __DELIMITEDPATH8_H__
williamr@2
    18
williamr@2
    19
/**
williamr@2
    20
	@file DelimitedPath8.h
williamr@2
    21
	Comments :	This file contains the API definition for the classes 
williamr@2
    22
				TDelimitedPathParser8 and CDelimitedPath16. 
williamr@2
    23
	@publishedAll
williamr@2
    24
	@released	
williamr@2
    25
 */
williamr@2
    26
williamr@2
    27
// System includes
williamr@2
    28
//
williamr@2
    29
#include <e32base.h>
williamr@2
    30
#include <delimitedparser8.h>
williamr@2
    31
williamr@2
    32
williamr@2
    33
/**
williamr@2
    34
Dependencies : TDelimitedParserBase8
williamr@2
    35
Comments : Derived class from TDelimitedParserBase providing a class for parsing 
williamr@2
    36
paths delimited by a '/' as defined in RFC2396.
williamr@2
    37
@publishedAll
williamr@2
    38
@released
williamr@2
    39
@since 6.0
williamr@2
    40
*/
williamr@2
    41
class TDelimitedPathParser8 : public TDelimitedParserBase8
williamr@2
    42
	{
williamr@2
    43
public:	// Methods
williamr@2
    44
williamr@2
    45
	IMPORT_C TDelimitedPathParser8();
williamr@2
    46
williamr@2
    47
	IMPORT_C void Parse(const TDesC8& aPath);
williamr@2
    48
williamr@2
    49
	IMPORT_C void ParseReverse(const TDesC8& aPath);
williamr@2
    50
	};
williamr@2
    51
williamr@2
    52
/**
williamr@2
    53
Dependencies : CDelimitedStringBase8
williamr@2
    54
Comments : Provides functionality to create a delimited path where components of the 
williamr@2
    55
path delimited by '/' as defined in RFC2396.
williamr@2
    56
@publishedAll
williamr@2
    57
@released
williamr@2
    58
@since 6.0
williamr@2
    59
*/
williamr@2
    60
class CDelimitedPath8 : public CDelimitedDataBase8
williamr@2
    61
	{
williamr@2
    62
public:	// Methods
williamr@2
    63
williamr@2
    64
/**
williamr@2
    65
	Static factory constructor. Uses two phase construction and leaves nothing
williamr@2
    66
	on the CleanupStack.
williamr@2
    67
	@since			6.0
williamr@2
    68
	@param			aPath	A descriptor with the initial path.
williamr@2
    69
	@return			A pointer to created object.
williamr@2
    70
	@post			Nothing left on the CleanupStack.
williamr@2
    71
 */
williamr@2
    72
	IMPORT_C static CDelimitedPath8* NewL(const TDesC8& aPath);
williamr@2
    73
williamr@2
    74
/**
williamr@2
    75
	Static factory constructor. Uses two phase construction and leaves a
williamr@2
    76
	pointer to created object on the CleanupStack.
williamr@2
    77
	@since			6.0
williamr@2
    78
	@param			aPath	A descriptor with the initial path.
williamr@2
    79
	@return			A pointer to created object.
williamr@2
    80
	@post			Pointer to created object left of CleanupStack.
williamr@2
    81
 */
williamr@2
    82
	IMPORT_C static CDelimitedPath8* NewLC(const TDesC8& aPath);
williamr@2
    83
williamr@2
    84
/**
williamr@2
    85
	Destructor.
williamr@2
    86
	@since			6.0
williamr@2
    87
 */
williamr@2
    88
	IMPORT_C ~CDelimitedPath8();
williamr@2
    89
williamr@2
    90
/**
williamr@2
    91
	Escape encodes the segment then inserts the escaped version in a 
williamr@2
    92
	position before the current parsed segment. The new segment should only contain a
williamr@2
    93
	single path segment, as any path delimiters in the segment will be converted to an
williamr@2
    94
	escape triple. The parser is left in a state where its current segment is the same
williamr@2
    95
	one as before the insertion.
williamr@2
    96
	@since			6.0
williamr@2
    97
	@param			aSegment	A descriptor with the unescaped path segment.
williamr@2
    98
	@pre 			The path must have been initially parsed.
williamr@2
    99
	@post			The path will have been extended to include the new segment. The 
williamr@2
   100
	current segment will remain as the one before the insertion.
williamr@2
   101
 */
williamr@2
   102
	IMPORT_C void InsertAndEscapeCurrentL(const TDesC8& aSegment);
williamr@2
   103
williamr@2
   104
/**
williamr@2
   105
	Escape encodes the segment then inserts the escaped version at 
williamr@2
   106
	the front of the path. The new segment should only contain a single path segment, 
williamr@2
   107
	as any path delimiters in the segment will be converted to an escape triple. The 
williamr@2
   108
	parser is left in a state where its current segment is the same one as before 
williamr@2
   109
	the insertion.
williamr@2
   110
	@warning		A re-parse is required to ensure that the parser is valid.
williamr@2
   111
	@since			6.0
williamr@2
   112
	@param			aSegment	A descriptor with the unescaped path segment.
williamr@2
   113
	@pre 			The delimiter must have been set. 
williamr@2
   114
	@post			The path will have been extended to include the new segment.
williamr@2
   115
 */
williamr@2
   116
	IMPORT_C void PushAndEscapeFrontL(const TDesC8& aSegment);
williamr@2
   117
williamr@2
   118
/**
williamr@2
   119
	Escape encodes the segment then inserts the escaped version at 
williamr@2
   120
	the back of the path. The new segment should only contain a single path segment, 
williamr@2
   121
	as any path delimiters in the segment will be converted to an escape triple. The 
williamr@2
   122
	parser is left in a state where its current segment is the same one as before 
williamr@2
   123
	the insertion.
williamr@2
   124
	@warning		A re-parse is required to ensure that the parser is valid.
williamr@2
   125
	@since			6.0
williamr@2
   126
	@param			aSegment	A descriptor with the unescaped path segment.
williamr@2
   127
	@pre 			The delimiter must have been set. 
williamr@2
   128
	@post			The path will have been extended to include the new segment.
williamr@2
   129
 */
williamr@2
   130
	IMPORT_C void PushAndEscapeBackL(const TDesC8& aSegment);
williamr@2
   131
williamr@2
   132
private:	// Methods
williamr@2
   133
williamr@2
   134
/**
williamr@2
   135
	Constructor. First phase of two-phase construction method. Does
williamr@2
   136
	non-allocating construction.
williamr@2
   137
	@since			6.0
williamr@2
   138
 */
williamr@2
   139
	CDelimitedPath8();
williamr@2
   140
williamr@2
   141
/**
williamr@2
   142
	Second phase of two-phase construction method. Does any allocations required
williamr@2
   143
	to fully construct the object.
williamr@2
   144
	@since			6.0
williamr@2
   145
	@param			aPath	A descriptor with the initial path.
williamr@2
   146
	@pre 			First phase of construction is complete.
williamr@2
   147
	@post			The object is fully constructed.
williamr@2
   148
 */
williamr@2
   149
	void ConstructL(const TDesC8& aPath);
williamr@2
   150
williamr@2
   151
	};
williamr@2
   152
williamr@2
   153
#endif	// __DELIMITEDPATH8_H__