epoc32/include/uriutils.h
author William Roberts <williamr@symbian.org>
Tue, 16 Mar 2010 16:12:26 +0000
branchSymbian2
changeset 2 2fe1408b6811
parent 0 061f57f2323e
child 4 837f303aceeb
permissions -rw-r--r--
Final list of Symbian^2 public API header files
     1 // Copyright (c) 2001-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 the License "Symbian Foundation License v1.0" to Symbian Foundation members and "Symbian Foundation End User License Agreement v1.0" to non-members
     5 // which accompanies this distribution, and is available
     6 // at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
     7 //
     8 // Initial Contributors:
     9 // Nokia Corporation - initial contribution.
    10 //
    11 // Contributors:
    12 //
    13 // Description:
    14 // 
    15 // 
    16 //
    17 
    18 
    19 
    20 /**
    21  @file UriUtils.h
    22  @publishedAll
    23  @released
    24 */
    25 
    26 #ifndef __URIUTILS_H__
    27 #define __URIUTILS_H__
    28 
    29 // System includes
    30 //
    31 #include <e32base.h>
    32 #include <authority8.h>
    33 #include <uri8.h>
    34 #include <uri16.h>
    35 
    36 
    37 /**
    38   Comments :
    39   @publishedAll
    40   @released
    41 */
    42 class UriUtils
    43 	{
    44 public:
    45 /** 
    46 	Enum defining a flag used to indicate host type.
    47 	@publishedAll
    48 	@released
    49 	@since 9.1	
    50  */
    51 	enum TUriHostType
    52 		{
    53 		/** 
    54 			Indicates host is of type IPv6. Example: 1080:0:0:0:8:800:200C:417A 
    55 		 */
    56 		EIPv6Host,
    57 		/**
    58 			Indicates host is of type IPv4. Example: 192.168.202.18 
    59 		 */
    60 		EIPv4Host,
    61 		/** 
    62 			Indicates host is in text form. Example: www.mypage.com 
    63 		 */
    64 		ETextHost,
    65 		};
    66 
    67 	IMPORT_C static CUri8* ConvertToInternetFormL(const TUriC16& aUri);
    68 	IMPORT_C static CUri16* ConvertToDisplayFormL(const TUriC8& aUri);
    69 
    70 	IMPORT_C static CUri8* CreateUriL(const TDesC& aUri);
    71 	IMPORT_C static CAuthority8* CreateAuthorityL(const TDesC& aAuthority) ;
    72 
    73 	IMPORT_C static TBool HasInvalidChars(const TDesC8& aData);
    74 	IMPORT_C static TBool HasInvalidChars(const TDesC16& aData);
    75 
    76 	IMPORT_C static TUriHostType HostType(const TDesC8& aHost);
    77 	IMPORT_C static TUriHostType HostType(const TDesC16& aHost);
    78 	IMPORT_C static CUri8* NormaliseUriL(const TUriC8& aUri);
    79 	};
    80 
    81 #endif	// __URIUTILS_H__