--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/Symbian3/PDK/Source/GUID-5589AAB6-3801-5B3D-98D8-459508B4F836.dita Fri Jan 22 18:26:19 2010 +0000
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License
+"Eclipse Public License v1.0" which accompanies this distribution,
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+ Nokia Corporation - initial contribution.
+Contributors:
+-->
+<!DOCTYPE task
+ PUBLIC "-//OASIS//DTD DITA Task//EN" "task.dtd">
+<task xml:lang="en" id="GUID-5589AAB6-3801-5B3D-98D8-459508B4F836"><title>Adding a Feature </title><shortdesc>How to add a feature using <apiname>RFeatureControl</apiname>. </shortdesc><prolog><metadata><keywords/></metadata></prolog><taskbody><context id="GUID-BDDF1DE3-749E-5160-A024-85ED159615FD"><p>To add a feature using <xref href="GUID-F6AAAC24-4A62-383A-86C6-2E46335C3FD4.dita"><apiname>RFeatureControl</apiname></xref>, take the following steps. </p> </context> <steps id="GUID-4C0E9C11-5578-579E-AA59-C5B64DEE5A93"><step id="GUID-EC907746-891F-581A-8B73-73789CD78673"><cmd/><info>Determine the Uid of the feature you want to add, </info> </step> <step id="GUID-30E14BAB-8880-5FD8-ADD4-75DE16A41605"><cmd/><info>create an instance of <codeph>TFeatureEntry</codeph>, </info> </step> <step id="GUID-08BA717B-6DC3-5AD0-B652-288953BD29ED"><cmd/><info>set its Uid, feature flags and feature data to the correct values for the feature you want to add, </info> </step> <step id="GUID-715CAFEE-103C-5C53-A1ED-78D7F5EBA9ED"><cmd/><info>create an instance of <codeph>RFeatureControl</codeph>, </info> </step> <step id="GUID-8596BC02-7BF1-52F0-A17E-BBB8831E2B0C"><cmd/><info>call its <codeph>Open()</codeph> function, </info> </step> <step id="GUID-E78B086C-CC2F-5908-959C-26DFDFB97853"><cmd/><info>call its <codeph>AddFeature()</codeph> function with a reference to the <codeph>TFeatureEntry</codeph> as argument, and </info> </step> <step id="GUID-0DDD2DA2-9CF2-5BFC-BBC6-E210BCF2A528"><cmd/><info>call its <codeph>Close()</codeph> function. </info> </step> </steps> <result id="GUID-93342094-AAD2-59F5-B93F-382994138306"><p>The call to <codeph>AddFeature()</codeph> requires <codeph>WriteDeviceData</codeph> capability. It returns: </p> <ul><li id="GUID-94F3F586-38CD-5FD2-BB69-D6623757997F"><p> <codeph>KErrNone</codeph> if the feature was successfully added, </p> </li> <li id="GUID-3EFF3CD9-A7EB-58FE-B3B2-C2B4D52E2683"><p> <codeph>KPermissionDenied</codeph> if a capability check fails, </p> </li> <li id="GUID-358EBC60-F82B-51C0-996E-ED9FEA064811"><p> <codeph>KAlreadyExists</codeph> if the feature already exists, and </p> </li> <li id="GUID-C2CD27DC-5BEF-5FA1-B9D8-D4B89CF9CB13"><p>otherwise returns an error code. </p> </li> </ul> </result> </taskbody><related-links><link href="GUID-96D9B512-5F6C-51D8-9780-BB38643CD967.dita"><linktext>Enabling and disabling a
+ feature</linktext> </link> <link href="GUID-418388CE-88DC-5300-ADF4-400337FE975B.dita"><linktext>Setting and updating a
+ feature</linktext> </link> <link href="GUID-B71AC5E3-8AA8-55AD-916F-9E873926011B.dita"><linktext>Feature Manager Collection Overview</linktext> </link> <link href="GUID-D01C4682-619E-501E-8992-9F7FA35D7682.dita"><linktext>Feature Manager Modification Tutorials</linktext> </link> </related-links></task>
\ No newline at end of file