I want to generate the JavaDoc for my library excluding R and BuildConfig. The
RocketSpock's answer is almost there, but not quite (as of this writing). I can't comment yet, so I'll describe the process I used to exclude
BuildConfig.java from my Android library's Javadoc in Android Studio 1.2.2. There's basically an extra dialog that will come in very handy:
Open menu option
Tools --> Javadoc.
Custom scope. It's not necessary to select anything from
the drop-down menu yet.
...icon to open the
+icon. Give it a descriptive name if you wish.
Library Classes, since those are imports) navigate to the module(s) you wish to generate Javadoc for, and select any individual Java files you wish to include. In your case, you probably want to select an entire module but manually exclude
BuildConfig.java. When you're done, Click
OKto exit the Scopes dialog.
Specify Generate JavaDoc scopedialog, if your new scope is not selected in the
Custom scopedropdown menu, select it now, as well as any other additional options including output directory.
OKto generate your Javadoc.