docs: Javadoc cleanup
There were a number of Javadoc style problems in the
WifiNetworkSuggestion.Builder.build() docs, which caused some formatting
problems.
One specific problem worth noting: A {{ causes trouble at publish time,
because it looks like the start of a Django directive. But escaping the
{ -- e.g. { -- doesn't work, because the Javadoc compiler helpfully
escapes the *ampersand*, so the HTML output is "&#123", which
renders on the page as "{" instead of "{". So putting a space
between the two braces seems like the simplest solution.
No code changes here, just Javadoc comment fixes.
Tested by building the docs and staging to:
http://go/dac-stage/reference/android/net/wifi/WifiNetworkSuggestion.Builder#build
Screenshots (in case the stage gets overwritten):
https://screenshot.googleplex.com/o4p7efFGCbJ.png (1)
https://screenshot.googleplex.com/nkhEqU54LNb.png (2)
Bug: 128536865
Test: make ds-docs (then build & stage)
Change-Id: Ie04bc4dc517443a6899aba989beeb38b9299826e
This commit is contained in:
@@ -374,12 +374,11 @@ public final class WifiNetworkSuggestion implements Parcelable {
|
||||
}
|
||||
|
||||
/**
|
||||
* Create a network suggestion object use in
|
||||
* Create a network suggestion object for use in
|
||||
* {@link WifiManager#addNetworkSuggestions(List)}.
|
||||
*
|
||||
* See {@link WifiNetworkSuggestion}.
|
||||
*<p>
|
||||
* Note: Apps can set a combination of SSID using {@link #setSsid(String)} and BSSID
|
||||
*<p class="note">
|
||||
* <b>Note:</b> Apps can set a combination of SSID using {@link #setSsid(String)} and BSSID
|
||||
* using {@link #setBssid(MacAddress)} to provide more fine grained network suggestions to
|
||||
* the platform.
|
||||
* </p>
|
||||
@@ -387,7 +386,8 @@ public final class WifiNetworkSuggestion implements Parcelable {
|
||||
* For example:
|
||||
* To provide credentials for one open, one WPA2 and one WPA3 network with their
|
||||
* corresponding SSID's:
|
||||
* {@code
|
||||
*
|
||||
* <pre>{@code
|
||||
* final WifiNetworkSuggestion suggestion1 =
|
||||
* new Builder()
|
||||
* .setSsid("test111111")
|
||||
@@ -403,19 +403,20 @@ public final class WifiNetworkSuggestion implements Parcelable {
|
||||
* .setWpa3Passphrase("test6789")
|
||||
* .build()
|
||||
* final List<WifiNetworkSuggestion> suggestionsList =
|
||||
* new ArrayList<WifiNetworkSuggestion> {{
|
||||
* new ArrayList<WifiNetworkSuggestion> { {
|
||||
* add(suggestion1);
|
||||
* add(suggestion2);
|
||||
* add(suggestion3);
|
||||
* }};
|
||||
* } };
|
||||
* final WifiManager wifiManager =
|
||||
* context.getSystemService(Context.WIFI_SERVICE);
|
||||
* wifiManager.addNetworkSuggestions(suggestionsList);
|
||||
* ...
|
||||
* }
|
||||
* // ...
|
||||
* }</pre>
|
||||
*
|
||||
* @return Instance of {@link WifiNetworkSuggestion}.
|
||||
* @throws IllegalStateException on invalid params set.
|
||||
* @return Instance of {@link WifiNetworkSuggestion}
|
||||
* @throws IllegalStateException on invalid params set
|
||||
* @see WifiNetworkSuggestion
|
||||
*/
|
||||
public @NonNull WifiNetworkSuggestion build() {
|
||||
if (mSsid == null) {
|
||||
|
||||
Reference in New Issue
Block a user