imagingext_pub/exif_api/inc/ExifTag.h
changeset 0 469c91dae73b
equal deleted inserted replaced
-1:000000000000 0:469c91dae73b
       
     1 /*
       
     2 * Copyright (c) 2003, 2004 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:  Exif tag wrapper 
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 
       
    20 #ifndef EXIFTAG_H
       
    21 #define EXIFTAG_H
       
    22 
       
    23 //  INCLUDES
       
    24 #include <e32base.h>
       
    25 
       
    26 // CONSTANTS
       
    27 
       
    28 // MACROS
       
    29 
       
    30 // DATA TYPES
       
    31 
       
    32 // FUNCTION PROTOTYPES
       
    33 
       
    34 // FORWARD DECLARATIONS
       
    35 class TExifTagInfo;
       
    36 
       
    37 // CLASS DECLARATION
       
    38 
       
    39 /**
       
    40 *  Interface class for handling Exif Tags. 
       
    41 *  This class is used to get tag data from an Exif image.
       
    42 *  @lib ExifLib
       
    43 *  @since 2.6 
       
    44 */
       
    45 NONSHARABLE_CLASS( CExifTag ): public CBase
       
    46     {
       
    47 	public:  // Enumerations
       
    48 
       
    49         /**
       
    50         * Tag Data type enumeration.
       
    51         */
       
    52     	enum TExifTagDataType
       
    53             {
       
    54         	ETagByte = 1,
       
    55         	ETagAscii = 2,
       
    56         	ETagShort = 3,
       
    57         	ETagLong = 4,
       
    58         	ETagRational = 5,
       
    59         	ETagUndefined = 7,
       
    60         	ETagSlong = 9,
       
    61         	ETagSrational = 10
       
    62             };
       
    63 
       
    64     public:
       
    65         
       
    66         /**
       
    67         * Destructor.
       
    68         */
       
    69         virtual ~CExifTag();
       
    70 
       
    71     public: // New functions
       
    72         
       
    73         /**
       
    74         * Duplicate constructor. Creates an exact copy instance of the tag.
       
    75         * @since 2.6 
       
    76         * @param 
       
    77         * @return An instance of this class including the same contents of 
       
    78         * this instance.
       
    79         */
       
    80      	virtual CExifTag* DuplicateL() const = 0;
       
    81 
       
    82         /**
       
    83         * Returns the informative fields of a tag.
       
    84         * @since 2.6 
       
    85         * @param 
       
    86         * @return TExifTagInfo structure including informative fields of a tag
       
    87         */
       
    88     	virtual TExifTagInfo TagInfo() const = 0;
       
    89 
       
    90         /**
       
    91         * Returns data contents of a tag
       
    92         * @since 2.6 
       
    93         * @param 
       
    94         * @return Unmodifiable pointer to tag data.
       
    95         */
       
    96     	virtual TPtrC8 Data() const = 0;
       
    97 
       
    98     };
       
    99 
       
   100 
       
   101 class TExifTagInfo
       
   102     {    
       
   103     public:  // Constructors and destructor
       
   104 
       
   105         IMPORT_C TExifTagInfo( 
       
   106             TUint16 aTagId, 
       
   107             CExifTag::TExifTagDataType aDataType, 
       
   108             TUint32 aDataCount );
       
   109     
       
   110     public:     // Data
       
   111 
       
   112         // Tag ID
       
   113     	TUint16 iId;
       
   114 
       
   115         // Tag data type
       
   116     	CExifTag::TExifTagDataType iDataType;
       
   117 
       
   118         // Number of tag data elements (having tag data type).
       
   119     	TUint32 iDataCount;
       
   120     };
       
   121 
       
   122 #endif      // EXIFTAG_H   
       
   123             
       
   124 // End of File