Symbian3/SDK/Source/GUID-DCA2880E-7DF9-5E60-8F87-241711935389.dita
changeset 13 48780e181b38
parent 7 51a74ef9ed63
equal deleted inserted replaced
12:80ef3a206772 13:48780e181b38
     7     Nokia Corporation - initial contribution.
     7     Nokia Corporation - initial contribution.
     8 Contributors: 
     8 Contributors: 
     9 -->
     9 -->
    10 <!DOCTYPE concept
    10 <!DOCTYPE concept
    11   PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
    11   PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
    12 <concept id="GUID-DCA2880E-7DF9-5E60-8F87-241711935389" xml:lang="en"><title>FeatMngrExample:
    12 <concept id="GUID-DCA2880E-7DF9-5E60-8F87-241711935389" xml:lang="en"><title>FeatMngrExample: dynamic feature management example</title><shortdesc>This example demonstrates the use of Feature Manager APIs
    13 dynamic feature management example</title><shortdesc>This example demonstrates the use of Feature Manager APIs for dynamic
    13 for dynamic feature management. It also demonstrates how to receive
    14 feature management. It also demonstrates how to receive notification about
    14 notification about changes to a feature. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
    15 changes to a feature. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
    15 <section id="GUID-716F1987-F1F1-4E20-8390-BBD9AE592C2A"><title>Download</title> <p>Click on the following link to download the example: <xref href="guid-6013a680-57f9-415b-8851-c4fa63356636/zips/guid-3bc38b8f-c8bf-4af9-969b-a0bc4dd4dcad.zip" scope="external">FeatMngrExample.zip</xref></p><p>Click: <xref href="guid-6013a680-57f9-415b-8851-c4fa63356636/guid-3bc38b8f-c8bf-4af9-969b-a0bc4dd4dcad.html" scope="peer">browse</xref> to view the example code.</p> </section>
    16 <section id="GUID-716F1987-F1F1-4E20-8390-BBD9AE592C2A"><title>Download</title> <p>Click on the following link to download
    16 <section id="GUID-CA323EF2-3A8A-4363-AC6E-A21B3C2648D7"><title>Purpose</title> <p>The example shows how to use the <xref href="GUID-0CA63AEB-9A80-51C6-AE7F-E747D6B3B789.dita">Feature Manager</xref> API. UI vendors and device manufacturers can use this API to declare
    17 the example: <xref href="guid-6013a680-57f9-415b-8851-c4fa63356636/zips/guid-3bc38b8f-c8bf-4af9-969b-a0bc4dd4dcad.zip" scope="external">FeatMngrExample.zip</xref></p><p>Click: <xref href="guid-6013a680-57f9-415b-8851-c4fa63356636/guid-3bc38b8f-c8bf-4af9-969b-a0bc4dd4dcad.html" scope="peer">browse</xref> to view the example code.</p> </section>
    17 features (such as DRM agents, codecs, vibra) as available or not.
    18 <section id="GUID-CA323EF2-3A8A-4363-AC6E-A21B3C2648D7"><title>Purpose</title> <p>The example shows how to use the <xref href="GUID-0CA63AEB-9A80-51C6-AE7F-E747D6B3B789.dita">Feature Manager</xref> API.
    18 The feature set can be adjusted dynamically as software services are
    19 UI vendors and device manufacturers can use this API to declare features (such
    19 installed and uninstalled or as platform capabilities are discovered
    20 as DRM agents, codecs, vibra) as available or not. The feature set can be
    20 dynamically. </p> <p>This example shows how Feature Manager APIs allow
    21 adjusted dynamically as software services are installed and uninstalled or
    21 applications and system software to establish which features are present
    22 as platform capabilities are discovered dynamically. </p> <p>This example
    22 on or absent from a Symbian device. </p> </section>
    23 shows how Feature Manager APIs allow applications and system software to establish
    23 <section id="GUID-1C59222F-2F39-4599-8052-AE7C83854AC8"><title>Design
    24 which features are present on or absent from a Symbian device. </p> </section>
    24 and implementation</title> <p>The example consists of two processes: </p> <ul>
    25 <section id="GUID-1C59222F-2F39-4599-8052-AE7C83854AC8"><title>Design and implementation</title> <p>The example consists
    25 <li id="GUID-0DA213CD-55C2-5ADD-A872-20D008EE5D46"><p> <filepath>featmngrexample.exe</filepath>: this is the main process which provides the list of available features.
    26 of two processes: </p> <ul>
    26 It also provides the option to add new features or delete/update a
    27 <li id="GUID-0DA213CD-55C2-5ADD-A872-20D008EE5D46"><p> <filepath>featmngrexample.exe</filepath>:
    27 feature. </p> </li>
    28 this is the main process which provides the list of available features. It
    28 <li id="GUID-B2A151CA-3807-5990-B431-CF4083E42107"><p> <filepath>featurechecker.exe</filepath>: this process receives notification about new features installed
    29 also provides the option to add new features or delete/update a feature. </p> </li>
    29 or uninstalled by the main process. </p> </li>
    30 <li id="GUID-B2A151CA-3807-5990-B431-CF4083E42107"><p> <filepath>featurechecker.exe</filepath>:
    30 </ul> <p><b>FeatMngrExample</b> </p> <p>This shows the use of the <xref href="GUID-F6AAAC24-4A62-383A-86C6-2E46335C3FD4.dita"><apiname>RFeatureControl</apiname></xref> API to manage features. </p> <p>It presents
    31 this process receives notification about new features installed or uninstalled
    31 menu options to the user to list the available features, to add or
    32 by the main process. </p> </li>
    32 delete a feature, update an existing feature, and to enable or disable
    33 </ul> <p><b>FeatMngrExample</b> </p> <p>This shows the use of the <xref href="GUID-F6AAAC24-4A62-383A-86C6-2E46335C3FD4.dita"><apiname>RFeatureControl</apiname></xref> API
    33 a feature. It also starts another process, called featurechecker.exe
    34 to manage features. </p> <p>It presents menu options to the user to list the
    34 which receives notifications of events happening in this process.
    35 available features, to add or delete a feature, update an existing feature,
    35 The list of features includes some whose feature flags are non-modifiable.
    36 and to enable or disable a feature. It also starts another process, called
    36 Any attempt to modify or delete those features will result in a system
    37 featurechecker.exe which receives notifications of events happening in this
    37 error -21 (<codeph>KErrAccessDenied</codeph>). When adding a new feature,
    38 process. The list of features includes some whose feature flags are non-modifiable.
    38 it should be in the range as described in the console because the
    39 Any attempt to modify or delete those features will result in a system error
    39 featurechecker process subscribes to this range of features for change
    40 -21 (<codeph>KErrAccessDenied</codeph>). When adding a new feature, it should
    40 notification. </p> <p><b>FeatureChecker</b> </p> <p>This process is
    41 be in the range as described in the console because the featurechecker process
    41 started by <filepath>featmngrexample.exe</filepath>. It implements
    42 subscribes to this range of features for change notification. </p> <p><b>FeatureChecker</b> </p> <p>This
    42 the <xref href="GUID-623C4183-00F0-36B0-AE1F-5C5EDCAF1B3D.dita"><apiname>MFeatureObserver</apiname></xref> class to handle notification
    43 process is started by <filepath>featmngrexample.exe</filepath>. It implements
    43 of feature changes. <codeph>FeatureChecker</codeph> also demonstrates
    44 the <xref href="GUID-623C4183-00F0-36B0-AE1F-5C5EDCAF1B3D.dita"><apiname>MFeatureObserver</apiname></xref> class to handle notification of feature
    44 the use of the <xref href="GUID-CA12C6F7-E997-33B8-9463-B326BC1832C5.dita"><apiname>CFeatureNotifier</apiname></xref> class. It implements <codeph>HandleNotifyChange()</codeph> to handle the changes made by FeatMngrExample.
    45 changes. <codeph>FeatureChecker</codeph> also demonstrates the use of the <xref href="GUID-CA12C6F7-E997-33B8-9463-B326BC1832C5.dita"><apiname>CFeatureNotifier</apiname></xref> class.
    45 The type of change is displayed to the user as an infoprint message
    46 It implements <codeph>HandleNotifyChange()</codeph> to handle the changes
    46 (<xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-EEF84AA0-A277-390D-BFAB-CF50C94DF18D"><apiname>User::InfoPrint()</apiname></xref>). <codeph>HandleNotifyChange()</codeph> is called to handle changes for those features which are subscribed
    47 made by FeatMngrExample. The type of change is displayed to the user as an
    47 to for notification (in the <codeph>NotifyFeatureL</codeph> () method). </p> </section>
    48 infoprint message (<xref href="GUID-C197C9A7-EA05-3F24-9854-542E984C612D.dita#GUID-C197C9A7-EA05-3F24-9854-542E984C612D/GUID-EEF84AA0-A277-390D-BFAB-CF50C94DF18D"><apiname>User::InfoPrint()</apiname></xref>). <codeph>HandleNotifyChange()</codeph> is
    48 <section id="GUID-7A7C9409-D701-4C64-B0B2-AE0F89C396FA"><title>Building
    49 called to handle changes for those features which are subscribed to for notification
    49 and configuring</title> <p>To build the example: </p> <ul>
    50 (in the <codeph>NotifyFeatureL</codeph> () method). </p> </section>
    50 <li id="GUID-A8030260-4FEF-55E1-A50C-65BEE3F08E21"><p>The example
    51 <section id="GUID-7A7C9409-D701-4C64-B0B2-AE0F89C396FA"><title>Building and configuring</title> <p>To build the example: </p> <ul>
    51 builds two executables called <filepath>featmngrexample.exe</filepath> and <filepath>featurechecker.exe</filepath> in the standard locations.
    52 <li id="GUID-A8030260-4FEF-55E1-A50C-65BEE3F08E21"><p>The example builds two
    52 The second executable is run by the first. </p> </li>
    53 executables called <filepath>featmngrexample.exe</filepath> and <filepath>featurechecker.exe</filepath> in
    53 <li id="GUID-DD5D4965-A174-553C-BD13-22A6DFE9E52F"><p>You can build
    54 the standard locations. The second executable is run by the first. </p> </li>
    54 the example from your IDE or the command line. </p> <p>If you use
    55 <li id="GUID-DD5D4965-A174-553C-BD13-22A6DFE9E52F"><p>You can build the example
    55 an IDE, import the <filepath>bld.inf</filepath> file of the example
    56 from your IDE or the command line. </p> <p>If you use an IDE, import the <filepath>bld.inf</filepath> file
    56 into your IDE, and use the build command of the IDE. </p> <p>If you
    57 of the example into your IDE, and use the build command of the IDE. </p> <p>If
    57 use the command line, open a command prompt, and set the current directory
    58 you use the command line, open a command prompt, and set the current directory
    58 to the source code directory of the example. You can then build the
    59 to the source code directory of the example. You can then build the example
    59 example with the SBSv1 build tools with the following commands: </p> <p><userinput>bldmake bldfiles</userinput> </p> <p><userinput>abld
    60 with the SBSv1 build tools with the following commands: </p> <p><userinput>bldmake
    60 build</userinput> </p> </li>
    61 bldfiles</userinput> </p> <p><userinput>abld build</userinput> </p> <p><xref href="GUID-793A5EF9-CC16-5EEB-9011-6431EA76EB15.dita">How to use bldmake</xref> and <xref href="GUID-B6B54E07-3B34-5D5C-8815-93383FA8FB4B.dita">How to use abld</xref> describe
       
    62 how to use the SBSv1 build tools. </p> </li>
       
    63 </ul> </section>
    61 </ul> </section>
    64 <section id="GUID-8B18A01A-44D4-400E-9CEC-3E75F55D7F7F"><title>Running the example</title> <p>When running the example, the
    62 <section id="GUID-8B18A01A-44D4-400E-9CEC-3E75F55D7F7F"><title>Running
    65 user is presented with various menu options that are self-explanatory. Press
    63 the example</title> <p>When running the example, the user is presented
    66 any other key to exit. </p> </section>
    64 with various menu options that are self-explanatory. Press any other
    67 <section id="GUID-433F7103-5372-5971-85A6-0FBF88ECE5C1"><title>See also:</title><p><xref href="GUID-7495B1C8-38B5-5A09-8231-25B3BBC09F51.dita">Feature Management</xref></p></section>
    65 key to exit. </p> </section>
       
    66 <section id="GUID-433F7103-5372-5971-85A6-0FBF88ECE5C1"><title>See
       
    67 also:</title><p><xref href="GUID-7495B1C8-38B5-5A09-8231-25B3BBC09F51.dita">Feature Management</xref></p></section>
    68 </conbody></concept>
    68 </conbody></concept>