DITA-OT_CXX_Plugin/cxxapiref/doc/cxxEnumeration/cxxEnumeration.dita
changeset 4 468f4c8d3d5b
equal deleted inserted replaced
3:d8fccb2cd802 4:468f4c8d3d5b
       
     1 <?xml version="1.0" encoding="UTF-8"?>
       
     2 <!--
       
     3 Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies).
       
     4 All rights reserved.		
       
     5 		-->
       
     6 <!DOCTYPE reference PUBLIC "-//OASIS//DTD DITA Reference//EN" "reference.dtd">
       
     7 <reference xml:lang="en-us" outputclass="element" id="cxxEnumeration">
       
     8     <title>cxxEnumeration</title>
       
     9     <shortdesc>The &lt;cxxEnumeration&gt; element contains all the elements needed to describe the declaration of a C++ enumeration.</shortdesc>
       
    10     <refbody>
       
    11         <section>
       
    12             <title>Description</title>
       
    13             <p>The &lt;cxxEnumeration&gt; element requires
       
    14 an <i>id</i> attribute as an anchor point; id must always be specified. The
       
    15 id attribute is referenced by the <i>conref</i> attribute from internal applications
       
    16 that refer to the &lt;cxxFunctiion&gt; element content. The elements &lt;apiName&gt; 
       
    17 and &lt;cxxEnumerationDetail&gt; are required for this top-level container. </p>
       
    18         </section>
       
    19         <example>
       
    20             <title>Example</title>
       
    21             <codeblock>&lt;cxxEnumeration id="class_b_trace_1a289a8c50777f50be7f2d0535670c1e8d"&gt;
       
    22     &lt;apiName&gt;THeaderStructure&lt;/apiName&gt;
       
    23     &lt;cxxEnumerationDetail&gt;
       
    24         &lt;cxxEnumerationDefinition&gt;
       
    25             &lt;cxxEnumerationAccessSpecifier value="public"/&gt;
       
    26             &lt;cxxEnumerationScopedName&gt;BTrace&lt;/cxxEnumerationScopedName&gt;
       
    27             &lt;cxxEnumerationPrototype&gt;THeaderStructure&lt;/cxxEnumerationPrototype&gt;
       
    28             &lt;cxxEnumerationNameLookup&gt;BTrace:THeaderStructure&lt;/cxxEnumerationNameLookup&gt;
       
    29             &lt;cxxEnumerators&gt;
       
    30                 &lt;cxxEnumerator id="class_b_trace_1a289a8c50777f50be7f2d0535670c1e8daacb3d2fc73e5d51e0cfe218fe61a4a64"&gt;
       
    31                     &lt;apiName&gt;ESizeIndex&lt;/apiName&gt;
       
    32                     &lt;cxxEnumeratorScopedName&gt;BTrace&lt;/cxxEnumeratorScopedName&gt;
       
    33                     &lt;cxxEnumeratorPrototype&gt;ESizeIndex = 0&lt;/cxxEnumeratorPrototype&gt;
       
    34                     &lt;cxxEnumeratorNameLookup&gt;BTrace::ESizeIndex&lt;/cxxEnumeratorNameLookup&gt;
       
    35                     &lt;cxxEnumeratorInitialiser value="0"/&gt;
       
    36                     &lt;cxxEnumeratorAPIItemLocation&gt;
       
    37                         &lt;cxxEnumeratorDeclarationFile name="filePath" value="C:/src/include/e32btrace.h"/&gt;
       
    38                         &lt;cxxEnumeratorDeclarationFileLine name="lineNumber" value="177"/&gt;
       
    39                     &lt;/cxxEnumeratorAPIItemLocation&gt;
       
    40                     &lt;apiDesc&gt;
       
    41                         &lt;p&gt;Size of record in bytes. &lt;/p&gt;
       
    42                     &lt;/apiDesc&gt;
       
    43                 &lt;/cxxEnumerator&gt;
       
    44                 &lt;cxxEnumerator id="class_b_trace_1a289a8c50777f50be7f2d0535670c1e8da88aa2174423cbfd0a14b6bc857e06745"&gt;
       
    45                     &lt;apiName&gt;EFlagsIndex&lt;/apiName&gt;
       
    46                     &lt;cxxEnumeratorScopedName&gt;BTrace&lt;/cxxEnumeratorScopedName&gt;
       
    47                     &lt;cxxEnumeratorPrototype&gt;EFlagsIndex = 1&lt;/cxxEnumeratorPrototype&gt;
       
    48                     &lt;cxxEnumeratorNameLookup&gt;BTrace::EFlagsIndex&lt;/cxxEnumeratorNameLookup&gt;
       
    49                     &lt;cxxEnumeratorInitialiser value="1"/&gt;
       
    50                     &lt;cxxEnumeratorAPIItemLocation&gt;
       
    51                         &lt;cxxEnumeratorDeclarationFile name="filePath" value="C:/src/include/e32btrace.h"/&gt;
       
    52                         &lt;cxxEnumeratorDeclarationFileLine name="lineNumber" value="190"/&gt;
       
    53                     &lt;/cxxEnumeratorAPIItemLocation&gt;
       
    54                     &lt;apiDesc&gt;
       
    55                         &lt;p&gt;Bitfield of flags from enum TFlags. E.g. to detect if a timestamp is present in the record, code like this could be used. &lt;codeblock&gt;			TUint8* record; // pointer to trace record
       
    56         if(record[BTrace::EFlagsIndex]&amp;BTrace::ETimestampPresent)
       
    57             TimestampPresent();
       
    58         else
       
    59             TimestampNotPresent();&lt;/codeblock&gt; &lt;/p&gt;
       
    60                     &lt;/apiDesc&gt;
       
    61                 &lt;/cxxEnumerator&gt;
       
    62             &lt;/cxxEnumerators&gt;
       
    63             &lt;cxxEnumerationAPIItemLocation&gt;
       
    64                 &lt;cxxEnumerationDeclarationFile name="filePath" value="C:/src/include/e32btrace.h"/&gt;
       
    65                 &lt;cxxEnumerationDeclarationFileLine name="lineNumber" value="173"/&gt;
       
    66                 &lt;cxxEnumerationDefinitionFile name="filePath" value="C:/EPOC/master/sf/os/commsfw/serialserver/c32serialserver/CCOMM/CC_CLI.CPP"/&gt;
       
    67                 &lt;cxxEnumerationDefinitionFileLineStart name="lineNumber" value="172"/&gt;
       
    68                 &lt;cxxEnumerationDefinitionFileLineEnd name="lineNumber" value="201"/&gt;
       
    69             &lt;/cxxEnumerationAPIItemLocation&gt;
       
    70         &lt;/cxxEnumerationDefinition&gt;
       
    71         &lt;apiDesc&gt;
       
    72             &lt;p&gt;Byte indices into the trace header for specific fields. &lt;/p&gt;
       
    73         &lt;/apiDesc&gt;
       
    74     &lt;/cxxEnumerationDetail&gt;
       
    75 &lt;/cxxEnumeration&gt;</codeblock>
       
    76         </example>
       
    77         <section conref="../packagedef.dita#cxxEnumeration-reference/cxxEnumeration-containedBy-section"/>
       
    78         <section conref="../packagedef.dita#cxxEnumeration-reference/cxxEnumeration-contains-section"/>
       
    79         <section conref="../packagedef.dita#cxxEnumeration-reference/cxxEnumeration-contentModel-section"/>
       
    80         <section conref="../packagedef.dita#cxxEnumeration-reference/cxxEnumeration-attList-section"/>
       
    81         <section conref="../packagedef.dita#cxxEnumeration-reference/cxxEnumeration-classValue-section"/>
       
    82     </refbody>
       
    83 </reference>