equal
deleted
inserted
replaced
|
1 // Copyright (c) 2000-2009 Nokia Corporation and/or its subsidiary(-ies). |
|
2 // All rights reserved. |
|
3 // This component and the accompanying materials are made available |
|
4 // under the terms of "Eclipse Public License v1.0" |
|
5 // which accompanies this distribution, and is available |
|
6 // at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
7 // |
|
8 // Initial Contributors: |
|
9 // Nokia Corporation - initial contribution. |
|
10 // |
|
11 // Contributors: |
|
12 // |
|
13 // Description: |
|
14 // |
|
15 |
|
16 #ifndef ENCODERVISITOR_H |
|
17 #define ENCODERVISITOR_H |
|
18 |
|
19 #include <e32base.h> |
|
20 #include <btsdp.h> |
|
21 #include "sdputil.h" |
|
22 #include "MAttributeVisitor.h" |
|
23 #include "DataEncoder.h" |
|
24 |
|
25 class CSdpAttr; |
|
26 class CSdpServRecord; |
|
27 |
|
28 NONSHARABLE_CLASS(CAttrEncoderVisitor) : public CBase, private MAttributeVisitor |
|
29 { |
|
30 public: |
|
31 IMPORT_C static CAttrEncoderVisitor *NewLC(TElementEncoder aEncoder); |
|
32 IMPORT_C static CAttrEncoderVisitor *NewL(TElementEncoder aEncoder); |
|
33 ~CAttrEncoderVisitor(); |
|
34 |
|
35 IMPORT_C static void EncodeAttributeL(TElementEncoder aEncoder, CSdpAttrValue &aSrcAttr); |
|
36 IMPORT_C void EncodeAttributeL(CSdpAttrValue &aSrcAttr); |
|
37 |
|
38 private: |
|
39 CAttrEncoderVisitor(TElementEncoder aEncoder); |
|
40 void ConstructL(); |
|
41 |
|
42 // Implementation of MAttributeVisitor interface |
|
43 void VisitAttributeL(CSdpAttr &aAttribute); |
|
44 void VisitAttributeValueL(CSdpAttrValue &aValue, TSdpElementType aType); |
|
45 void StartListL(CSdpAttrValueList &aList); |
|
46 void EndListL(); |
|
47 |
|
48 private: |
|
49 TElementEncoder iEncoder; |
|
50 }; |
|
51 |
|
52 |
|
53 #endif |