<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: dan1st</title>
    <description>The latest articles on DEV Community by dan1st (@dan1st).</description>
    <link>https://dev.to/dan1st</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F757681%2Fc7084e15-81e3-41ae-b29d-810dbc4fba1c.png</url>
      <title>DEV Community: dan1st</title>
      <link>https://dev.to/dan1st</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/dan1st"/>
    <language>en</language>
    <item>
      <title>JDoc4droid, an offline Javadoc viewer for Android</title>
      <dc:creator>dan1st</dc:creator>
      <pubDate>Fri, 03 Dec 2021 17:26:24 +0000</pubDate>
      <link>https://dev.to/dan1st/jdoc4droid-an-offline-javadoc-viewer-for-android-11l4</link>
      <guid>https://dev.to/dan1st/jdoc4droid-an-offline-javadoc-viewer-for-android-11l4</guid>
      <description>&lt;h3&gt;
  
  
  Why create a Javadoc viewer for Android?
&lt;/h3&gt;

&lt;p&gt;I like to hang out in online programming communities like &lt;a href="https://stackoverflow.com"&gt;StackOverflow&lt;/a&gt; or programming &lt;a href="https://discord.com"&gt;Discord&lt;/a&gt; servers. There, I often like to answer questions from other people. Since I also do that using my mobile phone, I had a problem: I don't know everything by heart and viewing Javadocs on mobile devices can be painful. With painful, I mean that one needs to look the documentation up first and javadocs are not optimized for mobile devices.&lt;/p&gt;

&lt;h3&gt;
  
  
  The app
&lt;/h3&gt;

&lt;p&gt;This is why I have created &lt;a href="https://github.com/danthe1st/JDoc4droid"&gt;JDoc4droid&lt;/a&gt;, an Android app that allows to download and view Javadocs from Oracle, Maven repositories and even use Javadocs from a local Javadoc JAR or ZIP file.&lt;/p&gt;

&lt;h3&gt;
  
  
  Download
&lt;/h3&gt;

&lt;p&gt;JDoc4droid is &lt;a href="https://play.google.com/store/apps/details?id=io.github.danthe1st.jdoc4droid"&gt;available in the Play Store&lt;/a&gt; and the sources &lt;a href="https://github.com/danthe1st/JDoc4droid"&gt;can be found on GitHub&lt;/a&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  How does it work?
&lt;/h3&gt;

&lt;p&gt;Artifacts deployed to maven repositories (normally) include a javadoc JAR. JDoc4droid downloads this file and saves it locally. &lt;/p&gt;

&lt;p&gt;For viewing classes, JDoc4droid looks for a file named &lt;code&gt;allclasses-index.html&lt;/code&gt; or &lt;code&gt;allclasses-noframe.html&lt;/code&gt; in the root of the Javadoc. This HTML file is parsed using &lt;a href="https://jsoup.org/"&gt;JSoup&lt;/a&gt; and the classes (including a link to the HTML Javadoc of the classes) are extracted to be shown.&lt;/p&gt;

&lt;p&gt;On the other hand, viewing classes works in a similar manner. When opening a class, the HTML Javadoc of the class is parsed utilising &lt;a href="https://jsoup.org/"&gt;JSoup&lt;/a&gt; once more and the contents are extracted to be displayed on screen.&lt;/p&gt;

&lt;h3&gt;
  
  
  Screenshots
&lt;/h3&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fwdziszg6bocqiull0rnd.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fwdziszg6bocqiull0rnd.png" alt="list and add Javadocs" width="800" height="1600"&gt;&lt;/a&gt;&lt;br&gt;
&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F3tu2i7cq9jkawkc2v9zy.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F3tu2i7cq9jkawkc2v9zy.png" alt="add Javadoc from Maven Repository" width="800" height="1600"&gt;&lt;/a&gt;&lt;br&gt;
&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fl5y3m06xpekfter1aeiz.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fl5y3m06xpekfter1aeiz.png" alt="Browse classes" width="800" height="1600"&gt;&lt;/a&gt;&lt;br&gt;
&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fu34fzo4l9kdr0ww20vh8.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fu34fzo4l9kdr0ww20vh8.png" alt="View class" width="800" height="1600"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;h3&gt;
  
  
  GitHub
&lt;/h3&gt;


&lt;div class="ltag-github-readme-tag"&gt;
  &lt;div class="readme-overview"&gt;
    &lt;h2&gt;
      &lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--A9-wwsHG--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev.to/assets/github-logo-5a155e1f9a670af7944dd5e12375bc76ed542ea80224905ecaf878b9157cdefc.svg" alt="GitHub logo"&gt;
      &lt;a href="https://github.com/danthe1st"&gt;
        danthe1st
      &lt;/a&gt; / &lt;a href="https://github.com/danthe1st/JDoc4droid"&gt;
        JDoc4droid
      &lt;/a&gt;
    &lt;/h2&gt;
    &lt;h3&gt;
      Javadoc viewer for android
    &lt;/h3&gt;
  &lt;/div&gt;
  &lt;div class="ltag-github-body"&gt;
    
&lt;div id="readme" class="md"&gt;
&lt;div class="markdown-heading"&gt;
&lt;h1 class="heading-element"&gt;JDoc4droid&lt;/h1&gt;

&lt;/div&gt;
&lt;p&gt;&lt;a href="https://play.google.com/store/apps/details?id=io.github.danthe1st.jdoc4droid&amp;amp;pcampaignid=pcampaignidMKT-Other-global-all-co-prtnr-py-PartBadge-Mar2515-1" rel="nofollow"&gt;&lt;img alt="Get it on Google Play" src="https://camo.githubusercontent.com/bf5c3d9991f2bc80b5500c332c9b00244661511938bb78626a30f06664d495fb/68747470733a2f2f706c61792e676f6f676c652e636f6d2f696e746c2f656e5f75732f6261646765732f7374617469632f696d616765732f6261646765732f656e5f62616467655f7765625f67656e657269632e706e67" width="100px"&gt;&lt;/a&gt;
&lt;a href="https://appgallery.cloud.huawei.com/ag/n/app/C106428613?channelId=GitHub&amp;amp;referrer=GitHub%2FJDoc4Droid&amp;amp;id=15665a90dc7b485284a9c2a550a532ab&amp;amp;s=4B8BD701AED95006AAEE8CBAE0B51F9D791788F627D0B51351072FAE477D5DC6&amp;amp;detailType=0&amp;amp;v=&amp;amp;callType=AGDLINK&amp;amp;installType=0000" rel="nofollow"&gt;&lt;img alt="Get it on AppGallery" src="https://res.cloudinary.com/practicaldev/image/fetch/s--D5b9nV3v--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://user-images.githubusercontent.com/34687786/177045465-8be6ed4b-ae27-4ab6-b405-e4e89f56bedc.png" width="100px"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;A Javadoc Viewer for Android&lt;/p&gt;
&lt;div class="markdown-heading"&gt;
&lt;h2 class="heading-element"&gt;Installation&lt;/h2&gt;

&lt;/div&gt;
&lt;p&gt;JDoc4droid can be installed from Google Play
&lt;a href="https://play.google.com/store/apps/details?id=io.github.danthe1st.jdoc4droid" rel="nofollow"&gt;here&lt;/a&gt;
or from Huawai AppGallery
&lt;a href="https://appgallery.cloud.huawei.com/ag/n/app/C106428613?channelId=GitHub&amp;amp;referrer=GitHub%2FJDoc4Droid&amp;amp;id=15665a90dc7b485284a9c2a550a532ab&amp;amp;s=4B8BD701AED95006AAEE8CBAE0B51F9D791788F627D0B51351072FAE477D5DC6&amp;amp;detailType=0&amp;amp;v=&amp;amp;callType=AGDLINK&amp;amp;installType=0000" rel="nofollow"&gt;here&lt;/a&gt;
but and it is also possible to download an APK of any commit from &lt;a href="https://github.com/danthe1st/JDoc4droid/actions"&gt;GitHub Actions&lt;/a&gt;.&lt;/p&gt;
&lt;div class="markdown-heading"&gt;
&lt;h2 class="heading-element"&gt;Setup with AndroidStudio&lt;/h2&gt;

&lt;/div&gt;
&lt;ul&gt;
&lt;li&gt;Install AndroidStudio&lt;/li&gt;
&lt;li&gt;Clone the project&lt;/li&gt;
&lt;li&gt;Open the project in AndroidStudio&lt;/li&gt;
&lt;li&gt;Connect an android device (emulator or real device) via adb&lt;/li&gt;
&lt;li&gt;Run it&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="markdown-heading"&gt;
&lt;h2 class="heading-element"&gt;Setup without IDE&lt;/h2&gt;

&lt;/div&gt;
&lt;ul&gt;
&lt;li&gt;Clone the project&lt;/li&gt;
&lt;li&gt;If you are using Windows, run &lt;code&gt;gradlew build&lt;/code&gt; in the project directory&lt;/li&gt;
&lt;li&gt;If you are using a UNIX-like operating system, run &lt;code&gt;./gradlew build&lt;/code&gt; in the project directory&lt;/li&gt;
&lt;li&gt;After the command finishes, you should find a file named &lt;code&gt;app-debug.apk&lt;/code&gt; in the directory &lt;code&gt;app/build/outputs/apk/debug&lt;/code&gt;
and a file named &lt;code&gt;app-release-unsigned.apk&lt;/code&gt; in the directory &lt;code&gt;app/build/outputs/apk/release&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;You can install the apk file on an android device (emulator or real device) and use it&lt;/li&gt;
&lt;/ul&gt;
&lt;/div&gt;



&lt;/div&gt;
&lt;br&gt;
  &lt;div class="gh-btn-container"&gt;&lt;a class="gh-btn" href="https://github.com/danthe1st/JDoc4droid"&gt;View on GitHub&lt;/a&gt;&lt;/div&gt;
&lt;br&gt;
&lt;/div&gt;
&lt;br&gt;


&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Frn5yf62dmzvbotcrh0za.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Frn5yf62dmzvbotcrh0za.png" alt="Logo Image" width="512" height="512"&gt;&lt;/a&gt;&lt;/p&gt;

</description>
      <category>java</category>
      <category>javadoc</category>
      <category>android</category>
      <category>programming</category>
    </item>
  </channel>
</rss>
