04a10f78f9bf37d1a1b14629dc3f9a6d69016c3c
[sdk/doc/content.git] / api-reference / native / style / index.html
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
2 <html>
3 <head>
4 <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
5 <meta http-equiv="X-UA-Compatible" content="IE=9"/>
6
7 <title>Main Page</title>
8 <link href="tabs.css" rel="stylesheet" type="text/css"/>
9 <link href="Tizen.css" rel="stylesheet" type="text/css" />
10
11
12
13 </head>
14 <body>
15 <div id="top"><!-- do not remove this div! -->
16
17
18 <!-- Generated by Doxygen 1.7.4 -->
19   <div id="navrow1" class="tabs">
20     <ul class="tablist">
21       <li class="current"><a href="index.html"><span>Main&#160;Page</span></a></li>
22       <li><a href="pages.html"><span>Related&#160;Pages</span></a></li>
23       <li><a href="modules.html"><span>Libraries</span></a></li>
24       <li><a href="namespaces.html"><span>Namespaces</span></a></li>
25       <li><a href="annotated.html"><span>Classes</span></a></li>
26       <li><a href="files.html"><span>Files</span></a></li>
27     </ul>
28   </div>
29 </div>
30 <div class="header">
31   <div class="headertitle">
32 <div class="title">Tizen native API Reference</div>  </div>
33 </div><!--header-->
34 <div class="contents">
35 <p>The Tizen native API Reference provides descriptions for all the Tizen C++ namespaces, classes, and methods. Tizen is the root namespace that
36  encompasses all other namespaces in the Tizen native framework. 
37 </p> 
38 <p>The following information is given for each namespace:</p>
39 <ul>
40 <li>Detailed description
41                 <ul type="square">
42                         <li>Required header file and libraries</li>
43                         <li>Namespace description</li>
44                         <li>Class diagram</li>
45                 </ul>
46 </li>
47         <li>Sub-namespaces (if they exist)</li>
48         <li>Variables and enumerations</li>
49 </ul>
50 <p>The following information is given for each class:</p>
51 <ul>
52         <li>Inheritance diagram</li>
53         <li>Class description</li>
54         <li>Sub-classes (if they exist)</li>
55         <li>Member functions </li>
56         </ul>
57 <p>The following subsections give information on how to use the Tizen native API Reference:</p>
58 <ol>
59         <li><a href="#Structure">Structure of Method Descriptions</a></li>
60         <li><a href="#Use_API">Using an API</a></li>
61         <li><a href="#Use_Pre">Using a Privileged API</a></li>
62         <li><a href="#Use_Feature">Using a Featured API</a></li>
63         <!-- <li><a href="#SignIn">Using Sign-in</a></li> -->
64 </ol>
65         
66                 <h3 id="Structure">Structure of Method Descriptions</h3>
67                 <p>In the member functions documentation for each class, the methods are described using a unified structure, illustrated 
68                 in the below example.
69                 </p>
70                 <div class="memitem">
71                         <div class="memproto">
72                                 <table class="memname">
73                                         <tr>
74                                                 <td class="memname">Tizen::Namespace::Class::Method  ( type param1, type param2 )</td>  
75                                         </tr>
76                                 </table>
77                         </div>
78                         <div class="memdoc">
79                                 <p>A brief description of the method.
80                                         <dl>
81                                                 <dt><b>Since: </b></dt>
82                                                 <dd>2.0</dd>
83                                         </dl>
84                                         <dl>
85                                                 <dt><b>Compatibility : </b></dt>
86                                                 <dd>Describes compatibility issues between different Tizen API versions.
87                                                 </dd>
88                                         </dl>
89                                         <dl>
90                                                 <dt><b>Privilege level:</b></dt>
91                                                 <dd>Defines the privilege level (such as public) which is an access level for the APIs, based on their influence on the public, partner, or platform.</dd>
92                                         </dl>
93                                         <dl>
94                                                 <dt><b>Privilege:</b></dt>
95                                                 <dd>Defines the privilege (such as http://tizen.org/privilege/setting) that must be declared in the manifest file of an application that uses this method.</dd>
96                                         </dl>
97                                         <dl>
98                                                 <dt><b>Precondition: </b></dt>
99                                                 <dd>Describes restrictions about using this method.</dd>
100                                         </dl>
101                                         <dl class="return">
102                                                 <dt><b>Returns:</b></dt>
103                                                 <dd>Describes the return values.</dd>
104                                         </dl>
105                                         <dl>
106                                                 <dt><b>Parameters: </b></dt>
107                                                 <dd>
108                                                         <table border="0" cellspacing="2" cellpadding="0">
109                                                         <tr>
110                                                         <td valign="top"><tt>[in]</tt>&nbsp;</td><td valign="top"><em>param1 </em>&nbsp;</td><td>Description of param1</td>
111                                                         </tr>
112                                                         </table>
113                                                 </dd>
114                                                 <dd>
115                                                         <table border="0" cellspacing="2" cellpadding="0">
116                                                         <tr>
117                                                         <td valign="top"><tt>[out]</tt>&nbsp;</td><td valign="top"><em>param2</em>&nbsp;</td><td> Description of param2</td>
118                                                         </tr>
119                                                         </table>
120                                                         
121                                                 </dd>
122                                         </dl>
123                                         <dl>
124                                                 <dt><b>Exceptions: </b></dt>
125                                                 <dd>
126                                                         <table border="0" cellspacing="2" cellpadding="0">
127                                                         <tr>
128                                                         <td valign="top"></td><td valign="top"><em>EXCEPTION1</em>&nbsp;</td><td>Description of exception1.</td>
129                                                         </tr>
130                                                         </table>
131                                                 </dd>
132
133                                                 <dd> 
134                                                 <table border="0" cellspacing="2" cellpadding="0">
135                                                         <tr>
136                                                         <td valign="top"></td><td valign="top"><em>EXCEPTION2</em>&nbsp;</td><td>Description of exception2.</td>
137                                                         </tr>
138                                                 </table>        
139                                                 </dd>   
140                                                         
141                                         </dl>
142                                         <dl class="remark">             
143                                                 <dt><b>Remarks: </b></dt>
144                                                 <dd>Gives important information regarding the use of the method.<br>
145                                                         For example: The specific error code can be accessed using the GetLastResult() method.</br>
146                                                 </dd>  
147                                         </dl>
148                                         <dl>
149                                                 <dt><b>See also: </b></dt>
150                                                 <dd>Gives links to other methods.
151                                                         For example: Tizen::namespace::Class::Method()
152                                                 </dd>
153                                         </dl>
154                                 </p>
155                         </div>
156                 </div>
157         
158 <p></p>
159         <h3 id="Use_API">Using an API</h3></li>
160         <p>To be able to use an API, you need to perform the following steps:</p>
161                 <ol>
162                         <p><li>Check the required header file.</li></p>
163                         <p>To use a specific API in a project, include its header file. The required include files are listed under
164                         <b>Remarks</b> in the Tizen native API Reference. For example, if an application uses the <span style="font-family: Courier New,Courier,monospace">Tizen::App::AppControl</span> 
165                         class, you must include <span style="font-family: Courier New,Courier,monospace">FApp.h</span> instead of <span style="font-family: Courier New,Courier,monospace">FAppAppControl.h</span> as shown under <b>Remarks</b> on the <b>Tizen::App</b> page.</p>
166                         <p><center><img src="Intro_using_an_api.png" border="0" alt=""/></center></p>
167                         <p><li>Add the required header file in the source code.</li></p>
168                         <p>For example, to use the <span style="font-family: Courier New,Courier,monospace">Tizen::App::AppControl</span> class, you must include the <span style="font-family: Courier New,Courier,monospace">FApp.h</span> file in the source code as illustrated below.</p>
169                         <p><center><img src="Intro_add_header_file.png" border="0" alt=""/></center></p>
170                         <p><li>Add the required libraries and library search paths in the application properties.</li></p>
171                         <p>In addition to the header file, it is also necessary to include the required libraries and their search paths in the application properties. The required libraries are listed under <b>Remarks</b> in the Tizen native API Reference. 
172                         <!--For more information, see the <a href="../com.osp.documentation.help/html/app_dev_process/adding_libraries_and_library_search_paths.htm">bada Developer Guide</a>.</p>-->
173                 </ol>
174         <h3 id="Use_Pre">Using a Privileged API</h3></li>
175                 <p>Some of the Tizen native APIs require privileges for security sensitive operations, and the privileges are categorized into three levels. When <b>Privilege level</b> and <b>Privilege</b> are included in a method description as shown below, declare the privilege and its level in the <span style="font-family: Courier New,Courier,monospace">manifest.xml</span> file. For more information, see <a href="../org.tizen.gettingstarted/html/tizen_overview/security.htm">Security Architecture</a>.</p>
176
177         <p><center><img src="Intro_using_a_privileged_api.png" border="0" alt=""/></center></p>
178         <!-- <p>Moreover, you must select <b>SOCKET</b> in <b>My Applications > Application Manager</b> on the bada developer site. </p>-->
179         <!-- <p><center><img src="Intro_privileged_api_group.png" border="0" alt=""/></center></p> -->
180         
181         <h3 id="Use_Feature">Using a Featured API</h3></li>
182                 <p>Some of the Tizen native APIs require features to prevent your application from being shown in the application list on the Tizen application store. When <b>Required feature</b> is included in a method description as shown below, declare the feature in the <span style="font-family: Courier New,Courier,monospace">manifest.xml</span> file. For more information, see <a href="../org.tizen.gettingstarted/html/tizen_overview/application_filtering.htm">Application Filtering</a>.</p>
183
184         <p><center><img src="Intro_using_a_featured_api.png" border="0" alt=""/></center></p>
185                 <!-- <li><h3><a name="SignIn" id="SignIn">Using Sign-in</a></h3></li>
186                 <p>An application can sign in to the bada Server using the sign-in application control. The sign in process includes user authentication. Therefore, the user of the application must have a user profile on the bada Server identified by a password.
187                 The sign-in application control supports single sign-on, which means that the user needs to sign in only once and can also use other applications that access the bada Server without signing in again.
188                 The authentication remains valid until the phone is shut down.</p>
189                 <p>The precondition for using the sign-in application control in a method is given below.</p>
190                 
191                 <div class="memitem">
192                         <div class="memproto">
193                                 <table class="memname">
194                                         <tr>
195                                                 <td class="memname"> </td>  
196                                         </tr>
197                                 </table>
198                         </div>
199                         <div class="memdoc">
200                                 <p>
201                                         <dl>
202                                                 <dt><b>Precondition: </b></dt>
203                                                 <dd>User should be authenticated.<br>
204                                                         For more information, see the sign-in application control (Tizen::App::APPCONTROL_PROVIDER_SIGNIN).</br></dd>
205                                         </dl>
206                                 </p>
207                         </div>
208                 </div> 
209  
210 <p>The following code snippet illustrates how to use the sign-in application control:</p>
211 <div class="fragment">
212 <pre class="fragment">    
213  <span class="keywordtype">void</span>
214  MyAppClass::AppControlSignInSample(<span class="keywordtype">void</span>)
215  {
216     ArrayList* pDataList = null;
217     AppControl* pAc = AppManager::FindAppControlN(<a class="code" href="namespaceOsp_1_1App.html#a801511da4f9e36a47a4d69fa32b44b6a">APPCONTROL_PROVIDER_SIGNIN</a>, 
218         <a class="code" href="namespaceOsp_1_1App.html#adab037972f557473da236beff2bd1882">APPCONTROL_OPERATION_SIGNIN</a>);
219     <span class="keywordflow">if</span>(pAc)
220     {
221         pAc->Start(null, <span class="keyword">this</span>);
222         <span class="keyword">delete</span>  pAc;
223     }
224  }
225   </pre>
226  </div>
227 </ol>
228 -->
229 </div> 
230
231 <hr size="1"> </hr>
232 <center>
233 <small>Except as noted, this content - excluding the Code Examples - is licensed under <a href="http://creativecommons.org/licenses/by/3.0/legalcode" target="_blank">Creative Commons Attribution 3.0</a>
234 and all of the Code Examples contained herein are licensed under <a href="https://www.tizen.org/bsd-3-clause-license" target="_blank">BSD-3-Clause</a>.<br>For details, see the <a href="https://www.tizen.org/content-license" target="_blank">Content License</a>.&nbsp;</small>
235 </center>
236
237 <script type="text/javascript">
238 var _gaq = _gaq || [];
239 _gaq.push(['_setAccount', 'UA-15055292-3']);
240 _gaq.push(['_trackPageview']);
241 (function() {
242 var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
243 ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
244 var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
245 })();
246 </script>
247
248 </body>
249 </html>