Add Documentation for API and Privilege Checker Tool. 53/138153/4
authorKarthik Bhat <kv.bhat@samsung.com>
Tue, 11 Jul 2017 08:39:51 +0000 (14:09 +0530)
committerEditor Lionbridge <TizenEditor.SEL@lionbridge.com>
Mon, 17 Jul 2017 10:55:01 +0000 (13:55 +0300)
PS2: Reviewed
PS3: Fixed minor formatting error
PS4: Took out .NET profile icons which have not yet been
approved.

Change-Id: Iced4039d3cc15724c674bf9f9d4912fa42da0df2
Signed-off-by: Karthik Bhat <kv.bhat@samsung.com>
preview/html/cover_page.htm
preview/html/images/api_checker_issues.png [new file with mode: 0644]
preview/html/images/api_checker_launch.png [new file with mode: 0644]
preview/html/images/api_checker_quickfix.png [new file with mode: 0644]
preview/html/index.htm
preview/html/introduction/overview.htm
preview/html/tools/api-privilege_checker.htm [new file with mode: 0644]
preview/html/tools/tools_overview.htm
preview/index.xml

index aef7dd5..18a1cc3 100644 (file)
@@ -30,7 +30,7 @@
 
 <p>The third preview of Tizen .NET, an application framework for Tizen based on .NET,  is now available. The third preview stepped forward. Key new features are as follows:</p>
 <ul>
-    <li><strong>New Tools</strong>. Device Manager and Log Viewer were introduced with Visual Studio Tools for Tizen.  Tizen-specific tools were added to further improve your productivity. </li>
+    <li><strong>New Tools</strong>. Device Manager, Log Viewer, and API and Privilege checker were introduced with Visual Studio Tools for Tizen.  Tizen-specific tools were added to further improve your productivity. </li>
 
     <li><strong>Project Wizard</strong>. Visual Studio Tools for Tizen provide a number of different options to build applications. For instance, you can build an application that runs on a single device type or an application that runs on multiple device types. You can build an application that runs on Tizen only or an application that runs on multiple platforms. The project wizard helps you to select the right project type with step-by-step guides.</li>
 
@@ -81,4 +81,4 @@ var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga
 
 </body>
 
-</html>
\ No newline at end of file
+</html>
diff --git a/preview/html/images/api_checker_issues.png b/preview/html/images/api_checker_issues.png
new file mode 100644 (file)
index 0000000..a81fff0
Binary files /dev/null and b/preview/html/images/api_checker_issues.png differ
diff --git a/preview/html/images/api_checker_launch.png b/preview/html/images/api_checker_launch.png
new file mode 100644 (file)
index 0000000..86a713a
Binary files /dev/null and b/preview/html/images/api_checker_launch.png differ
diff --git a/preview/html/images/api_checker_quickfix.png b/preview/html/images/api_checker_quickfix.png
new file mode 100644 (file)
index 0000000..9ac81bc
Binary files /dev/null and b/preview/html/images/api_checker_quickfix.png differ
index 8b8d169..38ea65c 100644 (file)
@@ -66,6 +66,7 @@
                 <li><a href="tools/emulator_control_panel.htm" target="content">Emulator Control Panel</a></li>
                 <li><a href="tools/device_manager.htm" target="content">Device Manager</a></li>
                 <li><a href="tools/log_viewer.htm" target="content">Log Viewer</a></li>
+               <li><a href="tools/api-privilege_checker.htm" target="content">API and Privilege Checker</a></li>
             </ul>
                </li>
     </ul>
index f3e9723..340ef11 100644 (file)
        The Tizen Device Manager&nbsp;is a tool that is used to manage connected Tizen devices or emulators, which is used to browse, push and pull files from them.&nbsp;</li>
        <li><a href="../tools/log_viewer.htm">Log Viewer</a><br />
        The Tizen Log Viewer&nbsp;is a tool that is used to see logs from connected Tizen&nbsp;devices or emulaotors.&nbsp;</li>
+       <li><a href="../tools/api-privilege_checker.htm">API and Privilege Checker</a><br />
+       The API and Privilege Checker is a tool that detects API and Privilege violations in Tizen .NET Applications.</li>
 </ul>
 
 
@@ -156,4 +158,4 @@ var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga
 
 </body>
 
-</html>
\ No newline at end of file
+</html>
diff --git a/preview/html/tools/api-privilege_checker.htm b/preview/html/tools/api-privilege_checker.htm
new file mode 100644 (file)
index 0000000..97c39b7
--- /dev/null
@@ -0,0 +1,101 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+
+<head>
+    <meta http-equiv="content-type" content="text/html; charset=utf-8" />
+    <meta http-equiv="X-UA-Compatible" content="IE=9" />
+    <link rel="stylesheet" type="text/css" href="../css/styles.css" />
+    <link rel="stylesheet" type="text/css" href="../css/snippet.css" />
+    <script type="text/javascript" src="../scripts/snippet.js"></script>
+    <script type="text/javascript" src="../scripts/jquery.util.js" charset="utf-8"></script>
+    <script type="text/javascript" src="../scripts/common.js" charset="utf-8"></script>
+    <script type="text/javascript" src="../scripts/core.js" charset="utf-8"></script>
+    <script type="text/javascript" src="../scripts/search.js" charset="utf-8"></script>
+    <title>API and Privilege Checker</title>
+</head>
+
+<body onload="prettyPrint()" style="overflow: auto;">
+<div id="toc-navigation">
+       <div id="profile">
+               <p><img alt="Mobile C#" src="../images/mobile_s_cs.png"/> <img alt="TV C#" src="../images/tv_s_cs.png"/></p>
+       </div>
+
+       <div id="toc_border"><div id="toc">
+               <p class="toc-title">Content</p>
+               <ul class="toc">
+                       <li><a href="#run">Running the API Checker</a></li>
+                       <li><a href="#quickfix">Quick-fixing API Checker Findings</a></li>
+               </ul>
+       </div></div>
+</div>
+
+<div id="container"><div id="contents"><div class="content">
+
+<h1>API and Privilege Checker</h1>
+
+<p>You can detect potential issues with privileges and APIs in your Tizen .NET application by using the API Checker tool.</p>
+
+<p>The API Checker currently detects the following issues in Tizen .NET applications:</p>
+<ul>
+       <li><strong>Undefined privileges</strong>
+       <p>Flags an error if the application uses a method which requires a privilege, but that privilege has not been defined in the application manifest file.</p>
+       <p>For example, the <code>GetCallHandleList()</code> method of the <a href="https://developer.tizen.org/dev-guide/csapi/classTizen_1_1Telephony_1_1Call.html">Tizen.Telephony.Call</a> class requires the <code>http://tizen.org/privilege/telephony</code> privilege. If an application uses this method without the privilege being defined in the manifest file, the method fails when you try to run the application.</p>
+       <p>The API Checker enables you to detect undefined privileges at compile time and fix them using the Quick Actions functionality in Visual Studio.</p>
+       </li>
+       <li><strong>Unused privileges</strong>
+       <p>Flags a warning if the application contains privileges that are not used by any APIs in the application.</p>
+       </li>
+</ul>
+
+<h2 id="run">Running the API Checker</h2>
+<p>To run the API Checker on your application:</p>
+<ol>
+<li>In the <strong>Solution Explorer</strong> view, select the project you want to analyze.</li>
+<li>In the Visual Studio menu, go to <strong>Tools &gt; Tizen &gt; Run APIChecker on Solution</strong>.
+<p align="center"><img alt="Run API and Privilege Checker" src="../images/api_checker_launch.png" /></p>
+<p>The project is automatically built and the API Checker is run during the build process.</p>
+<p>When checking is finished, the detected issues are listed in the <strong>Error List</strong> view. The view contains a detailed description of the issue, and the file and line in which the issue occurs. Undefined privileges are reported as errors, while unused privileges are reported as warnings.</p>
+
+<p align="center"><img alt="Error list" src="../images/api_checker_issues.png" /></p></li>
+
+</ol>
+
+<h2 id="quickfix">Quick-fixing API Checker Findings</h2>
+<p>You can quick-fix the undefined privileges found by the API Checker:</p>
+<ol>
+       <li>Click the applicable missing privilege error in the <strong>Error List</strong> view.
+       <p>The Quick Actions functionality in Visual Studio displays a light bulb button on the left margin, next to the code line with the error.</p></li>
+       <li>To automatically add the missing privilege to your manifest file, click the light bulb, and select the applicable item in the drop-down menu.
+       <p>You can see the newly-added privilege in the <code>tizen-manifest.xml</code> file, and the missing privilege errors related to this privilege are automatically removed from the <strong>Error List</strong> view.</p>
+       <p align="center"><img alt="" src="../images/api_checker_quickfix.png" /></p>
+       </li>
+</ol>
+
+
+
+<script type="text/javascript" src="../scripts/jquery.zclip.min.js"></script>
+<script type="text/javascript" src="../scripts/showhide.js"></script>
+
+</div></div></div>
+
+<a class="top sms" href="#"><img src="../images/btn_top.gif" alt="Go to top" /></a>
+
+<div id="footer">
+<p class="footer">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> 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>.</p>
+</div>
+
+<script type="text/javascript">
+var _gaq = _gaq || [];
+_gaq.push(['_setAccount', 'UA-25976949-1']);
+_gaq.push(['_trackPageview']);
+(function() {
+var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
+ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
+var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
+})();
+</script>
+
+</body>
+
+</html>
index 932257f..37d3148 100644 (file)
@@ -41,6 +41,9 @@
        The Device Manager&nbsp;<span>is a standalone tool that provides information&nbsp;of connected Tizen devices or emulators&nbsp;for application debugging.</span></li>
        <li><strong><a href="../tools/log_viewer.htm"><span>Log Viewer</span></a></strong><br />
        The Log Viewer <span>helps you debug your application by capturing all the events logged by the platform and your application.</span></li>
+       
+       <li><strong><a href="../tools/api-privilege_checker.htm">API and Privilege Checker</a></strong><br />
+       The API Checker tool checks for API and privilege usage violations in the application code. It helps you to identify and fix potential problems in the application code related to API and privilege use.</li>
 </ul>
 
 
@@ -68,4 +71,4 @@ var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga
 
 </body>
 
-</html>
\ No newline at end of file
+</html>
index d12e1c7..4da14ea 100644 (file)
@@ -26,5 +26,6 @@
        <topic href="html/tools/emulator_control_panel.htm" label="Emulator Control Panel"></topic>
        <topic href="html/tools/device_manager.htm" label="Device Manager"></topic>
        <topic href="html/tools/log_viewer.htm" label="Log Viewer"></topic>
+       <topic href="html/tools/api-privilege_checker.htm" label="API and Privilege Checker"></topic>
 </topic>
 </toc>