I am getting tired of the java doc warnings, so fix them.

Change-Id: I2205eebae419eaf4a0992c9f5b7cd807eb843fe1
This commit is contained in:
Dianne Hackborn
2009-08-21 15:14:02 -07:00
parent cf3a08307d
commit 4a51c20ce6
40 changed files with 233 additions and 101 deletions

View File

@ -14932,7 +14932,7 @@
synchronized="false" synchronized="false"
static="false" static="false"
final="false" final="false"
deprecated="deprecated" deprecated="not deprecated"
visibility="public" visibility="public"
> >
<parameter name="response" type="android.accounts.IAccountAuthenticatorResponse"> <parameter name="response" type="android.accounts.IAccountAuthenticatorResponse">
@ -115562,7 +115562,7 @@
synchronized="false" synchronized="false"
static="false" static="false"
final="false" final="false"
deprecated="not deprecated" deprecated="deprecated"
visibility="public" visibility="public"
> >
<parameter name="asu" type="int"> <parameter name="asu" type="int">

View File

@ -261,6 +261,7 @@ public class AccountManager {
} }
/** @deprecated use {@link #confirmCredentials} instead */ /** @deprecated use {@link #confirmCredentials} instead */
@Deprecated
public AccountManagerFuture<Boolean> confirmPassword(final Account account, final String password, public AccountManagerFuture<Boolean> confirmPassword(final Account account, final String password,
AccountManagerCallback<Boolean> callback, Handler handler) { AccountManagerCallback<Boolean> callback, Handler handler) {
return new Future2Task<Boolean>(handler, callback) { return new Future2Task<Boolean>(handler, callback) {

View File

@ -56,9 +56,11 @@ public interface AccountManagerFuture<V> extends Future<V> {
V getResult(long timeout, TimeUnit unit) V getResult(long timeout, TimeUnit unit)
throws OperationCanceledException, IOException, AuthenticatorException; throws OperationCanceledException, IOException, AuthenticatorException;
/** @deprecated Use {@link #getResult} */
@Deprecated @Deprecated
V get() throws InterruptedException, ExecutionException; V get() throws InterruptedException, ExecutionException;
/** @deprecated Use {@link #getResult} */
@Deprecated @Deprecated
V get(long timeout, TimeUnit unit) V get(long timeout, TimeUnit unit)
throws InterruptedException, ExecutionException, TimeoutException; throws InterruptedException, ExecutionException, TimeoutException;

View File

@ -32,7 +32,7 @@ oneway interface IAccountAuthenticator {
/** /**
* Checks that the account/password combination is valid. * Checks that the account/password combination is valid.
* @deprecated * note -- deprecated
*/ */
void confirmPassword(in IAccountAuthenticatorResponse response, void confirmPassword(in IAccountAuthenticatorResponse response,
in Account account, String password); in Account account, String password);

View File

@ -1769,6 +1769,7 @@ public class SearchManager
/** /**
* @deprecated This method is an obsolete internal implementation detail. Do not use. * @deprecated This method is an obsolete internal implementation detail. Do not use.
*/ */
@Deprecated
public void onCancel(DialogInterface dialog) { public void onCancel(DialogInterface dialog) {
throw new UnsupportedOperationException(); throw new UnsupportedOperationException();
} }
@ -1776,6 +1777,7 @@ public class SearchManager
/** /**
* @deprecated This method is an obsolete internal implementation detail. Do not use. * @deprecated This method is an obsolete internal implementation detail. Do not use.
*/ */
@Deprecated
public void onDismiss(DialogInterface dialog) { public void onDismiss(DialogInterface dialog) {
throw new UnsupportedOperationException(); throw new UnsupportedOperationException();
} }

View File

@ -887,6 +887,7 @@ public abstract class ContentResolver {
* @deprecated instead use * @deprecated instead use
* {@link #requestSync(android.accounts.Account, String, android.os.Bundle)} * {@link #requestSync(android.accounts.Account, String, android.os.Bundle)}
*/ */
@Deprecated
public void startSync(Uri uri, Bundle extras) { public void startSync(Uri uri, Bundle extras) {
Account account = null; Account account = null;
if (extras != null) { if (extras != null) {
@ -967,6 +968,7 @@ public abstract class ContentResolver {
* @param uri the uri of the provider to sync or null to sync all providers. * @param uri the uri of the provider to sync or null to sync all providers.
* @deprecated instead use {@link #cancelSync(android.accounts.Account, String)} * @deprecated instead use {@link #cancelSync(android.accounts.Account, String)}
*/ */
@Deprecated
public void cancelSync(Uri uri) { public void cancelSync(Uri uri) {
cancelSync(null /* all accounts */, uri != null ? uri.getAuthority() : null); cancelSync(null /* all accounts */, uri != null ? uri.getAuthority() : null);
} }

View File

@ -491,42 +491,49 @@ public abstract class Context {
* @deprecated Use {@link android.app.WallpaperManager#getDrawable * @deprecated Use {@link android.app.WallpaperManager#getDrawable
* WallpaperManager.get()} instead. * WallpaperManager.get()} instead.
*/ */
@Deprecated
public abstract Drawable getWallpaper(); public abstract Drawable getWallpaper();
/** /**
* @deprecated Use {@link android.app.WallpaperManager#peekDrawable * @deprecated Use {@link android.app.WallpaperManager#peekDrawable
* WallpaperManager.peek()} instead. * WallpaperManager.peek()} instead.
*/ */
@Deprecated
public abstract Drawable peekWallpaper(); public abstract Drawable peekWallpaper();
/** /**
* @deprecated Use {@link android.app.WallpaperManager#getDesiredMinimumWidth() * @deprecated Use {@link android.app.WallpaperManager#getDesiredMinimumWidth()
* WallpaperManager.getDesiredMinimumWidth()} instead. * WallpaperManager.getDesiredMinimumWidth()} instead.
*/ */
@Deprecated
public abstract int getWallpaperDesiredMinimumWidth(); public abstract int getWallpaperDesiredMinimumWidth();
/** /**
* @deprecated Use {@link android.app.WallpaperManager#getDesiredMinimumHeight() * @deprecated Use {@link android.app.WallpaperManager#getDesiredMinimumHeight()
* WallpaperManager.getDesiredMinimumHeight()} instead. * WallpaperManager.getDesiredMinimumHeight()} instead.
*/ */
@Deprecated
public abstract int getWallpaperDesiredMinimumHeight(); public abstract int getWallpaperDesiredMinimumHeight();
/** /**
* @deprecated Use {@link android.app.WallpaperManager#setBitmap(Bitmap) * @deprecated Use {@link android.app.WallpaperManager#setBitmap(Bitmap)
* WallpaperManager.set()} instead. * WallpaperManager.set()} instead.
*/ */
@Deprecated
public abstract void setWallpaper(Bitmap bitmap) throws IOException; public abstract void setWallpaper(Bitmap bitmap) throws IOException;
/** /**
* @deprecated Use {@link android.app.WallpaperManager#setStream(InputStream) * @deprecated Use {@link android.app.WallpaperManager#setStream(InputStream)
* WallpaperManager.set()} instead. * WallpaperManager.set()} instead.
*/ */
@Deprecated
public abstract void setWallpaper(InputStream data) throws IOException; public abstract void setWallpaper(InputStream data) throws IOException;
/** /**
* @deprecated Use {@link android.app.WallpaperManager#clear * @deprecated Use {@link android.app.WallpaperManager#clear
* WallpaperManager.clear()} instead. * WallpaperManager.clear()} instead.
*/ */
@Deprecated
public abstract void clearWallpaper() throws IOException; public abstract void clearWallpaper() throws IOException;
/** /**

View File

@ -123,7 +123,6 @@ interface IPackageManager {
* providers that can sync. * providers that can sync.
* @param outInfo Filled in with a list of the ProviderInfo for each * @param outInfo Filled in with a list of the ProviderInfo for each
* name in 'outNames'. * name in 'outNames'.
* @deprecated
*/ */
void querySyncProviders(inout List<String> outNames, void querySyncProviders(inout List<String> outNames,
inout List<ProviderInfo> outInfo); inout List<ProviderInfo> outInfo);

View File

@ -79,6 +79,7 @@ public final class ProviderInfo extends ComponentInfo
* @deprecated This flag is now being ignored. The current way to make a provider * @deprecated This flag is now being ignored. The current way to make a provider
* syncable is to provide a SyncAdapter service for a given provider/account type. * syncable is to provide a SyncAdapter service for a given provider/account type.
*/ */
@Deprecated
public boolean isSyncable = false; public boolean isSyncable = false;
public ProviderInfo() { public ProviderInfo() {

View File

@ -517,6 +517,7 @@ public class SQLiteDatabase extends SQLiteClosable {
* @deprecated if the db is locked more than once (becuase of nested transactions) then the lock * @deprecated if the db is locked more than once (becuase of nested transactions) then the lock
* will not be yielded. Use yieldIfContendedSafely instead. * will not be yielded. Use yieldIfContendedSafely instead.
*/ */
@Deprecated
public boolean yieldIfContended() { public boolean yieldIfContended() {
return yieldIfContendedHelper(false /* do not check yielding */); return yieldIfContendedHelper(false /* do not check yielding */);
} }

View File

@ -20,9 +20,8 @@ package android.hardware;
* Used for receiving notifications from the SensorManager when * Used for receiving notifications from the SensorManager when
* sensor values have changed. * sensor values have changed.
* *
* This interface is deprecated, use * @deprecated Use
* {@link android.hardware.SensorEventListener SensorEventListener} instead. * {@link android.hardware.SensorEventListener SensorEventListener} instead.
*
*/ */
@Deprecated @Deprecated
public interface SensorListener { public interface SensorListener {

View File

@ -116,47 +116,67 @@ public class SensorManager
@Deprecated @Deprecated
public static final int SENSOR_ORIENTATION_RAW = 1 << 7; public static final int SENSOR_ORIENTATION_RAW = 1 << 7;
/** A constant that includes all sensors */ /** A constant that includes all sensors
* @deprecated use {@link android.hardware.Sensor Sensor} instead.
*/
@Deprecated @Deprecated
public static final int SENSOR_ALL = 0x7F; public static final int SENSOR_ALL = 0x7F;
/** Smallest sensor ID */ /** Smallest sensor ID
* @deprecated use {@link android.hardware.Sensor Sensor} instead.
*/
@Deprecated @Deprecated
public static final int SENSOR_MIN = SENSOR_ORIENTATION; public static final int SENSOR_MIN = SENSOR_ORIENTATION;
/** Largest sensor ID */ /** Largest sensor ID
* @deprecated use {@link android.hardware.Sensor Sensor} instead.
*/
@Deprecated @Deprecated
public static final int SENSOR_MAX = ((SENSOR_ALL + 1)>>1); public static final int SENSOR_MAX = ((SENSOR_ALL + 1)>>1);
/** Index of the X value in the array returned by /** Index of the X value in the array returned by
* {@link android.hardware.SensorListener#onSensorChanged} */ * {@link android.hardware.SensorListener#onSensorChanged}
* @deprecated use {@link android.hardware.Sensor Sensor} instead.
*/
@Deprecated @Deprecated
public static final int DATA_X = 0; public static final int DATA_X = 0;
/** Index of the Y value in the array returned by /** Index of the Y value in the array returned by
* {@link android.hardware.SensorListener#onSensorChanged} */ * {@link android.hardware.SensorListener#onSensorChanged}
* @deprecated use {@link android.hardware.Sensor Sensor} instead.
*/
@Deprecated @Deprecated
public static final int DATA_Y = 1; public static final int DATA_Y = 1;
/** Index of the Z value in the array returned by /** Index of the Z value in the array returned by
* {@link android.hardware.SensorListener#onSensorChanged} */ * {@link android.hardware.SensorListener#onSensorChanged}
* @deprecated use {@link android.hardware.Sensor Sensor} instead.
*/
@Deprecated @Deprecated
public static final int DATA_Z = 2; public static final int DATA_Z = 2;
/** Offset to the untransformed values in the array returned by /** Offset to the untransformed values in the array returned by
* {@link android.hardware.SensorListener#onSensorChanged} */ * {@link android.hardware.SensorListener#onSensorChanged}
* @deprecated use {@link android.hardware.Sensor Sensor} instead.
*/
@Deprecated @Deprecated
public static final int RAW_DATA_INDEX = 3; public static final int RAW_DATA_INDEX = 3;
/** Index of the untransformed X value in the array returned by /** Index of the untransformed X value in the array returned by
* {@link android.hardware.SensorListener#onSensorChanged} */ * {@link android.hardware.SensorListener#onSensorChanged}
* @deprecated use {@link android.hardware.Sensor Sensor} instead.
*/
@Deprecated @Deprecated
public static final int RAW_DATA_X = 3; public static final int RAW_DATA_X = 3;
/** Index of the untransformed Y value in the array returned by /** Index of the untransformed Y value in the array returned by
* {@link android.hardware.SensorListener#onSensorChanged} */ * {@link android.hardware.SensorListener#onSensorChanged}
* @deprecated use {@link android.hardware.Sensor Sensor} instead.
*/
@Deprecated @Deprecated
public static final int RAW_DATA_Y = 4; public static final int RAW_DATA_Y = 4;
/** Index of the untransformed Z value in the array returned by /** Index of the untransformed Z value in the array returned by
* {@link android.hardware.SensorListener#onSensorChanged} */ * {@link android.hardware.SensorListener#onSensorChanged}
* @deprecated use {@link android.hardware.Sensor Sensor} instead.
*/
@Deprecated @Deprecated
public static final int RAW_DATA_Z = 5; public static final int RAW_DATA_Z = 5;

View File

@ -70,6 +70,7 @@ public class Build {
* *
* @deprecated Use {@link #SDK_INT} to easily get this as an integer. * @deprecated Use {@link #SDK_INT} to easily get this as an integer.
*/ */
@Deprecated
public static final String SDK = getString("ro.build.version.sdk"); public static final String SDK = getString("ro.build.version.sdk");
/** /**

View File

@ -56,22 +56,22 @@ import android.util.LogPrinter;
} }
class S1 extends HandlerState { class S1 extends HandlerState {
@Override public void enter(Message message) { &amp;#064;Override public void enter(Message message) {
} }
@Override public void processMessage(Message message) { &amp;#064;Override public void processMessage(Message message) {
deferMessage(message); deferMessage(message);
if (message.what == TEST_WHAT_2) { if (message.what == TEST_WHAT_2) {
transitionTo(mS2); transitionTo(mS2);
} }
} }
@Override public void exit(Message message) { &amp;#064;Override public void exit(Message message) {
} }
} }
class S2 extends HandlerState { class S2 extends HandlerState {
@Override public void processMessage(Message message) { &amp;#064;Override public void processMessage(Message message) {
// Do some processing // Do some processing
if (message.what == TEST_WHAT_2) { if (message.what == TEST_WHAT_2) {
transtionTo(mS1); transtionTo(mS1);

View File

@ -1521,8 +1521,9 @@ public final class Gmail {
/** /**
* Returns the number of conversation with a given label. * Returns the number of conversation with a given label.
* @deprecated * @deprecated Use {@link #getLabelId} instead.
*/ */
@Deprecated
public int getNumConversations(String label) { public int getNumConversations(String label) {
return getNumConversations(getLabelId(label)); return getNumConversations(getLabelId(label));
} }
@ -1534,8 +1535,9 @@ public final class Gmail {
/** /**
* Returns the number of unread conversation with a given label. * Returns the number of unread conversation with a given label.
* @deprecated * @deprecated Use {@link #getLabelId} instead.
*/ */
@Deprecated
public int getNumUnreadConversations(String label) { public int getNumUnreadConversations(String label) {
return getNumUnreadConversations(getLabelId(label)); return getNumUnreadConversations(getLabelId(label));
} }
@ -2040,8 +2042,9 @@ public final class Gmail {
} }
/** /**
* @deprecated * @deprecated Always returns true.
*/ */
@Deprecated
public boolean getExpanded() { public boolean getExpanded() {
return true; return true;
} }

View File

@ -45,7 +45,7 @@ import android.annotation.SdkConstant;
* public static class MyLiveFolder extends Activity { * public static class MyLiveFolder extends Activity {
* public static final Uri CONTENT_URI = Uri.parse("content://my.app/live"); * public static final Uri CONTENT_URI = Uri.parse("content://my.app/live");
* *
* @Override * &amp;#064;Override
* protected void onCreate(Bundle savedInstanceState) { * protected void onCreate(Bundle savedInstanceState) {
* super.onCreate(savedInstanceState); * super.onCreate(savedInstanceState);
* *

View File

@ -1522,18 +1522,17 @@ public final class Settings {
@Deprecated @Deprecated
public static final String USE_GOOGLE_MAIL = Secure.USE_GOOGLE_MAIL; public static final String USE_GOOGLE_MAIL = Secure.USE_GOOGLE_MAIL;
// /** /**
// * @deprecated Use {@link android.provider.Settings.Secure#WIFI_MAX_DHCP_RETRY_COUNT} * @deprecated Use
// * instead * {@link android.provider.Settings.Secure#WIFI_MAX_DHCP_RETRY_COUNT} instead
// */ */
@Deprecated @Deprecated
public static final String WIFI_MAX_DHCP_RETRY_COUNT = Secure.WIFI_MAX_DHCP_RETRY_COUNT; public static final String WIFI_MAX_DHCP_RETRY_COUNT = Secure.WIFI_MAX_DHCP_RETRY_COUNT;
// /** /**
// * @deprecated Use * @deprecated Use
// * {@link android.provider.Settings.Secure#WIFI_MOBILE_DATA_TRANSITION_WAKELOCK_TIMEOUT_MS} * {@link android.provider.Settings.Secure#WIFI_MOBILE_DATA_TRANSITION_WAKELOCK_TIMEOUT_MS} instead
// * instead */
// */
@Deprecated @Deprecated
public static final String WIFI_MOBILE_DATA_TRANSITION_WAKELOCK_TIMEOUT_MS = public static final String WIFI_MOBILE_DATA_TRANSITION_WAKELOCK_TIMEOUT_MS =
Secure.WIFI_MOBILE_DATA_TRANSITION_WAKELOCK_TIMEOUT_MS; Secure.WIFI_MOBILE_DATA_TRANSITION_WAKELOCK_TIMEOUT_MS;

View File

@ -36,6 +36,7 @@ public class ImageSpan extends DynamicDrawableSpan {
/** /**
* @deprecated Use {@link #ImageSpan(Context, Bitmap)} instead. * @deprecated Use {@link #ImageSpan(Context, Bitmap)} instead.
*/ */
@Deprecated
public ImageSpan(Bitmap b) { public ImageSpan(Bitmap b) {
this(null, b, ALIGN_BOTTOM); this(null, b, ALIGN_BOTTOM);
} }
@ -43,6 +44,7 @@ public class ImageSpan extends DynamicDrawableSpan {
/** /**
* @deprecated Use {@link #ImageSpan(Context, Bitmap, int) instead. * @deprecated Use {@link #ImageSpan(Context, Bitmap, int) instead.
*/ */
@Deprecated
public ImageSpan(Bitmap b, int verticalAlignment) { public ImageSpan(Bitmap b, int verticalAlignment) {
this(null, b, verticalAlignment); this(null, b, verticalAlignment);
} }

View File

@ -34,25 +34,25 @@ public final class Config
*/ */
/** /**
* Always the inverse of DEBUG. * @deprecated Use {@link #DEBUG} instead.
*/ */
@Deprecated @Deprecated
public static final boolean RELEASE = !DEBUG; public static final boolean RELEASE = !DEBUG;
/** /**
* Always false. * @deprecated Always false.
*/ */
@Deprecated @Deprecated
public static final boolean PROFILE = false; public static final boolean PROFILE = false;
/** /**
* Always false. * @deprecated Always false.
*/ */
@Deprecated @Deprecated
public static final boolean LOGV = false; public static final boolean LOGV = false;
/** /**
* Always true. * @deprecated Always true.
*/ */
@Deprecated @Deprecated
public static final boolean LOGD = true; public static final boolean LOGD = true;

View File

@ -319,7 +319,7 @@ public abstract class Animation implements Cloneable {
* *
* @param durationMillis Duration in milliseconds * @param durationMillis Duration in milliseconds
* *
* @throw java.lang.IllegalArgumentException if the duration is < 0 * @throws java.lang.IllegalArgumentException if the duration is < 0
* *
* @attr ref android.R.styleable#Animation_duration * @attr ref android.R.styleable#Animation_duration
*/ */

View File

@ -27,7 +27,7 @@ import android.webkit.WebView;
* Represents a plugin (Java equivalent of the PluginPackageAndroid * Represents a plugin (Java equivalent of the PluginPackageAndroid
* C++ class in libs/WebKitLib/WebKit/WebCore/plugins/android/) * C++ class in libs/WebKitLib/WebKit/WebCore/plugins/android/)
* *
* @deprecated This interface was inteded to be used by Gears. Since Gears was * @deprecated This interface was intended to be used by Gears. Since Gears was
* deprecated, so is this class. * deprecated, so is this class.
*/ */
@Deprecated @Deprecated
@ -43,7 +43,8 @@ public class Plugin {
private PreferencesClickHandler mHandler; private PreferencesClickHandler mHandler;
/** /**
* @deprecated * @deprecated This interface was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public Plugin(String name, public Plugin(String name,
@ -58,7 +59,8 @@ public class Plugin {
} }
/** /**
* @deprecated * @deprecated This interface was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public String toString() { public String toString() {
@ -66,7 +68,8 @@ public class Plugin {
} }
/** /**
* @deprecated * @deprecated This interface was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public String getName() { public String getName() {
@ -74,7 +77,8 @@ public class Plugin {
} }
/** /**
* @deprecated * @deprecated This interface was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public String getPath() { public String getPath() {
@ -82,7 +86,8 @@ public class Plugin {
} }
/** /**
* @deprecated * @deprecated This interface was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public String getFileName() { public String getFileName() {
@ -90,7 +95,8 @@ public class Plugin {
} }
/** /**
* @deprecated * @deprecated This interface was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public String getDescription() { public String getDescription() {
@ -98,7 +104,8 @@ public class Plugin {
} }
/** /**
* @deprecated * @deprecated This interface was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public void setName(String name) { public void setName(String name) {
@ -106,7 +113,8 @@ public class Plugin {
} }
/** /**
* @deprecated * @deprecated This interface was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public void setPath(String path) { public void setPath(String path) {
@ -114,7 +122,8 @@ public class Plugin {
} }
/** /**
* @deprecated * @deprecated This interface was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public void setFileName(String fileName) { public void setFileName(String fileName) {
@ -122,7 +131,8 @@ public class Plugin {
} }
/** /**
* @deprecated * @deprecated This interface was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public void setDescription(String description) { public void setDescription(String description) {
@ -130,7 +140,8 @@ public class Plugin {
} }
/** /**
* @deprecated * @deprecated This interface was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public void setClickHandler(PreferencesClickHandler handler) { public void setClickHandler(PreferencesClickHandler handler) {
@ -140,7 +151,8 @@ public class Plugin {
/** /**
* Invokes the click handler for this plugin. * Invokes the click handler for this plugin.
* *
* @deprecated * @deprecated This interface was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public void dispatchClickEvent(Context context) { public void dispatchClickEvent(Context context) {
@ -152,7 +164,8 @@ public class Plugin {
/** /**
* Default click handler. The plugins should implement their own. * Default click handler. The plugins should implement their own.
* *
* @deprecated * @deprecated This interface was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
private class DefaultClickHandler implements PreferencesClickHandler, private class DefaultClickHandler implements PreferencesClickHandler,
@ -172,7 +185,8 @@ public class Plugin {
} }
} }
/** /**
* @deprecated * @deprecated This interface was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public void onClick(DialogInterface dialog, int which) { public void onClick(DialogInterface dialog, int which) {

View File

@ -28,7 +28,7 @@ import java.util.Map;
* status code. The PluginData class is the container for all these * status code. The PluginData class is the container for all these
* parts. * parts.
* *
* @deprecated This class was inteded to be used by Gears. Since Gears was * @deprecated This class was intended to be used by Gears. Since Gears was
* deprecated, so is this class. * deprecated, so is this class.
*/ */
@Deprecated @Deprecated
@ -63,7 +63,8 @@ public final class PluginData {
* lowercase header name to [ unmodified header name, header value] * lowercase header name to [ unmodified header name, header value]
* @param length The HTTP response status code. * @param length The HTTP response status code.
* *
* @deprecated * @deprecated This class was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public PluginData( public PluginData(
@ -82,7 +83,8 @@ public final class PluginData {
* *
* @return An InputStream instance with the plugin content. * @return An InputStream instance with the plugin content.
* *
* @deprecated * @deprecated This class was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public InputStream getInputStream() { public InputStream getInputStream() {
@ -94,7 +96,8 @@ public final class PluginData {
* *
* @return the length of the plugin content. * @return the length of the plugin content.
* *
* @deprecated * @deprecated This class was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public long getContentLength() { public long getContentLength() {
@ -109,7 +112,8 @@ public final class PluginData {
* mapping is 'lowercase header name' to ['unmodified header * mapping is 'lowercase header name' to ['unmodified header
* name', header value]. * name', header value].
* *
* @deprecated * @deprecated This class was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public Map<String, String[]> getHeaders() { public Map<String, String[]> getHeaders() {
@ -121,7 +125,8 @@ public final class PluginData {
* *
* @return The HTTP statue code, e.g 200. * @return The HTTP statue code, e.g 200.
* *
* @deprecated * @deprecated This class was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public int getStatusCode() { public int getStatusCode() {

View File

@ -25,7 +25,7 @@ import java.util.List;
* populated when the plugins are initialized (at * populated when the plugins are initialized (at
* browser startup, at the moment). * browser startup, at the moment).
* *
* @deprecated This interface was inteded to be used by Gears. Since Gears was * @deprecated This interface was intended to be used by Gears. Since Gears was
* deprecated, so is this class. * deprecated, so is this class.
*/ */
@Deprecated @Deprecated
@ -35,7 +35,8 @@ public class PluginList {
/** /**
* Public constructor. Initializes the list of plugins. * Public constructor. Initializes the list of plugins.
* *
* @deprecated * @deprecated This interface was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public PluginList() { public PluginList() {
@ -45,7 +46,8 @@ public class PluginList {
/** /**
* Returns the list of plugins as a java.util.List. * Returns the list of plugins as a java.util.List.
* *
* @deprecated * @deprecated This interface was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public synchronized List getList() { public synchronized List getList() {
@ -55,7 +57,8 @@ public class PluginList {
/** /**
* Adds a plugin to the list. * Adds a plugin to the list.
* *
* @deprecated * @deprecated This interface was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public synchronized void addPlugin(Plugin plugin) { public synchronized void addPlugin(Plugin plugin) {
@ -67,7 +70,8 @@ public class PluginList {
/** /**
* Removes a plugin from the list. * Removes a plugin from the list.
* *
* @deprecated * @deprecated This interface was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public synchronized void removePlugin(Plugin plugin) { public synchronized void removePlugin(Plugin plugin) {
@ -80,7 +84,8 @@ public class PluginList {
/** /**
* Clears the plugin list. * Clears the plugin list.
* *
* @deprecated * @deprecated This interface was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public synchronized void clear() { public synchronized void clear() {
@ -90,7 +95,8 @@ public class PluginList {
/** /**
* Dispatches the click event to the appropriate plugin. * Dispatches the click event to the appropriate plugin.
* *
* @deprecated * @deprecated This interface was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public synchronized void pluginClicked(Context context, int position) { public synchronized void pluginClicked(Context context, int position) {

View File

@ -172,6 +172,7 @@ public final class URLUtil {
* requests from a file url. * requests from a file url.
* @deprecated Cookieless proxy is no longer supported. * @deprecated Cookieless proxy is no longer supported.
*/ */
@Deprecated
public static boolean isCookielessProxyUrl(String url) { public static boolean isCookielessProxyUrl(String url) {
return (null != url) && url.startsWith(PROXY_BASE); return (null != url) && url.startsWith(PROXY_BASE);
} }

View File

@ -25,7 +25,7 @@ import java.util.LinkedList;
import java.util.Map; import java.util.Map;
/** /**
* @deprecated This class was inteded to be used by Gears. Since Gears was * @deprecated This class was intended to be used by Gears. Since Gears was
* deprecated, so is this class. * deprecated, so is this class.
*/ */
@Deprecated @Deprecated
@ -48,7 +48,8 @@ public final class UrlInterceptRegistry {
* *
* @param disabled true to disable the cache * @param disabled true to disable the cache
* *
* @deprecated * @deprecated This class was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public static synchronized void setUrlInterceptDisabled(boolean disabled) { public static synchronized void setUrlInterceptDisabled(boolean disabled) {
@ -60,7 +61,8 @@ public final class UrlInterceptRegistry {
* *
* @return return if it is disabled * @return return if it is disabled
* *
* @deprecated * @deprecated This class was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public static synchronized boolean urlInterceptDisabled() { public static synchronized boolean urlInterceptDisabled() {
@ -74,7 +76,8 @@ public final class UrlInterceptRegistry {
* @param handler The new UrlInterceptHandler object * @param handler The new UrlInterceptHandler object
* @return true if the handler was not previously registered. * @return true if the handler was not previously registered.
* *
* @deprecated * @deprecated This class was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public static synchronized boolean registerHandler( public static synchronized boolean registerHandler(
@ -93,7 +96,8 @@ public final class UrlInterceptRegistry {
* @param handler A previously registered UrlInterceptHandler. * @param handler A previously registered UrlInterceptHandler.
* @return true if the handler was found and removed from the list. * @return true if the handler was found and removed from the list.
* *
* @deprecated * @deprecated This class was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public static synchronized boolean unregisterHandler( public static synchronized boolean unregisterHandler(
@ -107,7 +111,8 @@ public final class UrlInterceptRegistry {
* *
* @return A CacheResult containing surrogate content. * @return A CacheResult containing surrogate content.
* *
* @deprecated * @deprecated This class was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public static synchronized CacheResult getSurrogate( public static synchronized CacheResult getSurrogate(
@ -133,7 +138,8 @@ public final class UrlInterceptRegistry {
* *
* @return A PluginData instance containing surrogate content. * @return A PluginData instance containing surrogate content.
* *
* @deprecated * @deprecated This class was intended to be used by Gears. Since Gears was
* deprecated, so is this class.
*/ */
@Deprecated @Deprecated
public static synchronized PluginData getPluginData( public static synchronized PluginData getPluginData(

View File

@ -76,6 +76,7 @@ public class BitmapDrawable extends Drawable {
* @deprecated Use {@link #BitmapDrawable(Resources)} to ensure * @deprecated Use {@link #BitmapDrawable(Resources)} to ensure
* that the drawable has correctly set its target density. * that the drawable has correctly set its target density.
*/ */
@Deprecated
public BitmapDrawable() { public BitmapDrawable() {
mBitmapState = new BitmapState((Bitmap) null); mBitmapState = new BitmapState((Bitmap) null);
} }
@ -97,6 +98,7 @@ public class BitmapDrawable extends Drawable {
* @deprecated Use {@link #BitmapDrawable(Resources, Bitmap)} to ensure * @deprecated Use {@link #BitmapDrawable(Resources, Bitmap)} to ensure
* that the drawable has correctly set its target density. * that the drawable has correctly set its target density.
*/ */
@Deprecated
public BitmapDrawable(Bitmap bitmap) { public BitmapDrawable(Bitmap bitmap) {
this(new BitmapState(bitmap)); this(new BitmapState(bitmap));
} }

View File

@ -56,6 +56,7 @@ public class NinePatchDrawable extends Drawable {
* @deprecated Use {@link #NinePatchDrawable(Resources, Bitmap, byte[], Rect, String)} * @deprecated Use {@link #NinePatchDrawable(Resources, Bitmap, byte[], Rect, String)}
* to ensure that the drawable has correctly set its target density. * to ensure that the drawable has correctly set its target density.
*/ */
@Deprecated
public NinePatchDrawable(Bitmap bitmap, byte[] chunk, Rect padding, String srcName) { public NinePatchDrawable(Bitmap bitmap, byte[] chunk, Rect padding, String srcName) {
this(new NinePatchState(new NinePatch(bitmap, chunk, srcName), padding)); this(new NinePatchState(new NinePatch(bitmap, chunk, srcName), padding));
} }
@ -78,6 +79,7 @@ public class NinePatchDrawable extends Drawable {
* @deprecated Use {@link #NinePatchDrawable(Resources, NinePatch)} * @deprecated Use {@link #NinePatchDrawable(Resources, NinePatch)}
* to ensure that the drawable has correctly set its target density. * to ensure that the drawable has correctly set its target density.
*/ */
@Deprecated
public NinePatchDrawable(NinePatch patch) { public NinePatchDrawable(NinePatch patch) {
this(new NinePatchState(patch, null)); this(new NinePatchState(patch, null));
} }

View File

@ -816,37 +816,44 @@ public class AudioManager {
/* Routing bits for setRouting/getRouting API */ /* Routing bits for setRouting/getRouting API */
/** /**
* Routing audio output to earpiece * Routing audio output to earpiece
* @deprecated * @deprecated Do not set audio routing directly, use setSpeakerphoneOn(),
* setBluetoothScoOn() methods instead.
*/ */
@Deprecated public static final int ROUTE_EARPIECE = AudioSystem.ROUTE_EARPIECE; @Deprecated public static final int ROUTE_EARPIECE = AudioSystem.ROUTE_EARPIECE;
/** /**
* Routing audio output to spaker * Routing audio output to speaker
* @deprecated * @deprecated Do not set audio routing directly, use setSpeakerphoneOn(),
* setBluetoothScoOn() methods instead.
*/ */
@Deprecated public static final int ROUTE_SPEAKER = AudioSystem.ROUTE_SPEAKER; @Deprecated public static final int ROUTE_SPEAKER = AudioSystem.ROUTE_SPEAKER;
/** /**
* @deprecated use {@link #ROUTE_BLUETOOTH_SCO} * @deprecated use {@link #ROUTE_BLUETOOTH_SCO}
* @deprecated * @deprecated Do not set audio routing directly, use setSpeakerphoneOn(),
* setBluetoothScoOn() methods instead.
*/ */
@Deprecated public static final int ROUTE_BLUETOOTH = AudioSystem.ROUTE_BLUETOOTH_SCO; @Deprecated public static final int ROUTE_BLUETOOTH = AudioSystem.ROUTE_BLUETOOTH_SCO;
/** /**
* Routing audio output to bluetooth SCO * Routing audio output to bluetooth SCO
* @deprecated * @deprecated Do not set audio routing directly, use setSpeakerphoneOn(),
* setBluetoothScoOn() methods instead.
*/ */
@Deprecated public static final int ROUTE_BLUETOOTH_SCO = AudioSystem.ROUTE_BLUETOOTH_SCO; @Deprecated public static final int ROUTE_BLUETOOTH_SCO = AudioSystem.ROUTE_BLUETOOTH_SCO;
/** /**
* Routing audio output to headset * Routing audio output to headset
* @deprecated * @deprecated Do not set audio routing directly, use setSpeakerphoneOn(),
* setBluetoothScoOn() methods instead.
*/ */
@Deprecated public static final int ROUTE_HEADSET = AudioSystem.ROUTE_HEADSET; @Deprecated public static final int ROUTE_HEADSET = AudioSystem.ROUTE_HEADSET;
/** /**
* Routing audio output to bluetooth A2DP * Routing audio output to bluetooth A2DP
* @deprecated * @deprecated Do not set audio routing directly, use setSpeakerphoneOn(),
* setBluetoothScoOn() methods instead.
*/ */
@Deprecated public static final int ROUTE_BLUETOOTH_A2DP = AudioSystem.ROUTE_BLUETOOTH_A2DP; @Deprecated public static final int ROUTE_BLUETOOTH_A2DP = AudioSystem.ROUTE_BLUETOOTH_A2DP;
/** /**
* Used for mask parameter of {@link #setRouting(int,int,int)}. * Used for mask parameter of {@link #setRouting(int,int,int)}.
* @deprecated * @deprecated Do not set audio routing directly, use setSpeakerphoneOn(),
* setBluetoothScoOn() methods instead.
*/ */
@Deprecated public static final int ROUTE_ALL = AudioSystem.ROUTE_ALL; @Deprecated public static final int ROUTE_ALL = AudioSystem.ROUTE_ALL;

View File

@ -93,8 +93,9 @@ public class AudioSystem
* *
* return the current audio mode (NORMAL, RINGTONE, or IN_CALL). * return the current audio mode (NORMAL, RINGTONE, or IN_CALL).
* Returns the current current audio state from the HAL. * Returns the current current audio state from the HAL.
*
*/ */
/** @deprecated */ /** @deprecated Do not use. */
public static int getMode() { public static int getMode() {
return MODE_INVALID; return MODE_INVALID;
} }

View File

@ -539,7 +539,7 @@ public class MediaPlayer
* @param request Parcel with the data for the extension. The * @param request Parcel with the data for the extension. The
* caller must use {@link #newRequest()} to get one. * caller must use {@link #newRequest()} to get one.
* *
* @param[out] reply Parcel with the data returned by the * @param reply Output parcel with the data returned by the
* native player. * native player.
* *
* @return The status code see utils/Errors.h * @return The status code see utils/Errors.h

View File

@ -168,7 +168,7 @@ public class MediaRecorder
/** The following formats are audio only .aac or .amr formats **/ /** The following formats are audio only .aac or .amr formats **/
/** @deprecated Deprecated in favor of AMR_NB */ /** @deprecated Deprecated in favor of AMR_NB */
/** @todo change link when AMR_NB is exposed. Deprecated in favor of {@link MediaRecorder.OutputFormat#AMR_NB} */ /** TODO: change link when AMR_NB is exposed. Deprecated in favor of {@link MediaRecorder.OutputFormat#AMR_NB} */
public static final int RAW_AMR = 3; public static final int RAW_AMR = 3;
/** @hide AMR NB file format */ /** @hide AMR NB file format */
public static final int AMR_NB = 3; public static final int AMR_NB = 3;

View File

@ -154,8 +154,9 @@ public class PhoneStateListener {
* @see ServiceState#STATE_IN_SERVICE * @see ServiceState#STATE_IN_SERVICE
* @see ServiceState#STATE_OUT_OF_SERVICE * @see ServiceState#STATE_OUT_OF_SERVICE
* @see ServiceState#STATE_POWER_OFF * @see ServiceState#STATE_POWER_OFF
* @deprecated, @see #onSignalStrengthsChanged * @deprecated see #onSignalStrengthsChanged
*/ */
@Deprecated
public void onSignalStrengthChanged(int asu) { public void onSignalStrengthChanged(int asu) {
// default implementation empty // default implementation empty
} }

View File

@ -345,6 +345,7 @@ public class SmsMessage {
* the number of code units used, and int[2] is the number of code * the number of code units used, and int[2] is the number of code
* units remaining until the next message. int[3] is the encoding * units remaining until the next message. int[3] is the encoding
* type that should be used for the message. * type that should be used for the message.
* @deprecated Use android.telephony.SmsMessage.
*/ */
@Deprecated @Deprecated
public static int[] calculateLength(String messageBody, boolean use7bitOnly) { public static int[] calculateLength(String messageBody, boolean use7bitOnly) {

View File

@ -607,8 +607,9 @@ public interface CommandsInterface {
* ar.exception carries exception on failure * ar.exception carries exception on failure
* ar.userObject contains the orignal value of result.obj * ar.userObject contains the orignal value of result.obj
* ar.result contains a List of DataCallState * ar.result contains a List of DataCallState
* @deprecated * @deprecated Do not use.
*/ */
@Deprecated
void getPDPContextList(Message result); void getPDPContextList(Message result);
/** /**
@ -779,8 +780,9 @@ public interface CommandsInterface {
* cause code returned as int[0] in Message.obj.response * cause code returned as int[0] in Message.obj.response
* returns an integer cause code defined in TS 24.008 * returns an integer cause code defined in TS 24.008
* section 6.1.3.1.3 or close approximation * section 6.1.3.1.3 or close approximation
* @deprecated * @deprecated Do not use.
*/ */
@Deprecated
void getLastPdpFailCause (Message result); void getLastPdpFailCause (Message result);
/** /**

View File

@ -618,7 +618,7 @@ public abstract class PhoneBase implements Phone {
* This should only be called in GSM mode. * This should only be called in GSM mode.
* Only here for some backward compatibility * Only here for some backward compatibility
* issues concerning the GSMPhone class. * issues concerning the GSMPhone class.
* @deprecated * @deprecated Always returns null.
*/ */
public List<PdpConnection> getCurrentPdpList() { public List<PdpConnection> getCurrentPdpList() {
return null; return null;

View File

@ -1084,8 +1084,9 @@ public class GSMPhone extends PhoneBase {
} }
/** /**
* @deprecated * @deprecated Do not use.
*/ */
@Deprecated
public void getPdpContextList(Message response) { public void getPdpContextList(Message response) {
getDataCallList(response); getDataCallList(response);
} }
@ -1095,8 +1096,9 @@ public class GSMPhone extends PhoneBase {
} }
/** /**
* @deprecated * @deprecated Do not use.
*/ */
@Deprecated
public List<PdpConnection> getCurrentPdpList() { public List<PdpConnection> getCurrentPdpList() {
ArrayList<DataConnection> connections = new ArrayList<DataConnection>(); ArrayList<DataConnection> connections = new ArrayList<DataConnection>();
ArrayList<PdpConnection> pdp_list = new ArrayList<PdpConnection>(); ArrayList<PdpConnection> pdp_list = new ArrayList<PdpConnection>();

View File

@ -15,6 +15,7 @@ import android.database.DatabaseUtils;
* @deprecated this class extends InstrumentationTestCase but should extend AndroidTestCase. Use * @deprecated this class extends InstrumentationTestCase but should extend AndroidTestCase. Use
* ProviderTestCase2, which corrects this problem, instead. * ProviderTestCase2, which corrects this problem, instead.
*/ */
@Deprecated
public abstract class ProviderTestCase<T extends ContentProvider> public abstract class ProviderTestCase<T extends ContentProvider>
extends InstrumentationTestCase { extends InstrumentationTestCase {

View File

@ -565,6 +565,7 @@ public class TouchUtils {
* {@link android.test.ActivityInstrumentationTestCase2}, which provides more options for * {@link android.test.ActivityInstrumentationTestCase2}, which provides more options for
* configuring the Activity under test * configuring the Activity under test
*/ */
@Deprecated
public static int dragViewBy(InstrumentationTestCase test, View v, int gravity, int deltaX, public static int dragViewBy(InstrumentationTestCase test, View v, int gravity, int deltaX,
int deltaY) { int deltaY) {
int[] xy = new int[2]; int[] xy = new int[2];

View File

@ -1238,10 +1238,16 @@ static status_t writeLayoutClasses(
NA = idents.size(); NA = idents.size();
bool deprecated = false;
String16 comment = symbols->getComment(realClassName); String16 comment = symbols->getComment(realClassName);
fprintf(fp, "%s/** ", indentStr); fprintf(fp, "%s/** ", indentStr);
if (comment.size() > 0) { if (comment.size() > 0) {
fprintf(fp, "%s\n", String8(comment).string()); String8 cmt(comment);
fprintf(fp, "%s\n", cmt.string());
if (strstr(cmt.string(), "@deprecated") != NULL) {
deprecated = true;
}
} else { } else {
fprintf(fp, "Attributes that can be used with a %s.\n", nclassName.string()); fprintf(fp, "Attributes that can be used with a %s.\n", nclassName.string());
} }
@ -1317,6 +1323,10 @@ static status_t writeLayoutClasses(
} }
fprintf(fp, "%s */\n", getIndentSpace(indent)); fprintf(fp, "%s */\n", getIndentSpace(indent));
if (deprecated) {
fprintf(fp, "%s@Deprecated\n", indentStr);
}
fprintf(fp, fprintf(fp,
"%spublic static final int[] %s = {\n" "%spublic static final int[] %s = {\n"
"%s", "%s",
@ -1366,10 +1376,16 @@ static status_t writeLayoutClasses(
// String8(attr16).string(), String8(name16).string(), typeSpecFlags); // String8(attr16).string(), String8(name16).string(), typeSpecFlags);
const bool pub = (typeSpecFlags&ResTable_typeSpec::SPEC_PUBLIC) != 0; const bool pub = (typeSpecFlags&ResTable_typeSpec::SPEC_PUBLIC) != 0;
bool deprecated = false;
fprintf(fp, "%s/**\n", indentStr); fprintf(fp, "%s/**\n", indentStr);
if (comment.size() > 0) { if (comment.size() > 0) {
String8 cmt(comment);
fprintf(fp, "%s <p>\n%s @attr description\n", indentStr, indentStr); fprintf(fp, "%s <p>\n%s @attr description\n", indentStr, indentStr);
fprintf(fp, "%s %s\n", indentStr, String8(comment).string()); fprintf(fp, "%s %s\n", indentStr, cmt.string());
if (strstr(cmt.string(), "@deprecated") != NULL) {
deprecated = true;
}
} else { } else {
fprintf(fp, fprintf(fp,
"%s <p>This symbol is the offset where the {@link %s.R.attr#%s}\n" "%s <p>This symbol is the offset where the {@link %s.R.attr#%s}\n"
@ -1381,7 +1397,11 @@ static status_t writeLayoutClasses(
indentStr, nclassName.string()); indentStr, nclassName.string());
} }
if (typeComment.size() > 0) { if (typeComment.size() > 0) {
fprintf(fp, "\n\n%s %s\n", indentStr, String8(typeComment).string()); String8 cmt(typeComment);
fprintf(fp, "\n\n%s %s\n", indentStr, cmt.string());
if (strstr(cmt.string(), "@deprecated") != NULL) {
deprecated = true;
}
} }
if (comment.size() > 0) { if (comment.size() > 0) {
if (pub) { if (pub) {
@ -1399,6 +1419,9 @@ static status_t writeLayoutClasses(
fprintf(fp, "%s @attr name %s:%s\n", indentStr, fprintf(fp, "%s @attr name %s:%s\n", indentStr,
"android", String8(name).string()); "android", String8(name).string());
fprintf(fp, "%s*/\n", indentStr); fprintf(fp, "%s*/\n", indentStr);
if (deprecated) {
fprintf(fp, "%s@Deprecated\n", indentStr);
}
fprintf(fp, fprintf(fp,
"%spublic static final int %s_%s = %d;\n", "%spublic static final int %s_%s = %d;\n",
indentStr, nclassName.string(), indentStr, nclassName.string(),
@ -1440,11 +1463,16 @@ static status_t writeSymbolClass(
} }
String16 comment(sym.comment); String16 comment(sym.comment);
bool haveComment = false; bool haveComment = false;
bool deprecated = false;
if (comment.size() > 0) { if (comment.size() > 0) {
haveComment = true; haveComment = true;
String8 cmt(comment);
fprintf(fp, fprintf(fp,
"%s/** %s\n", "%s/** %s\n",
getIndentSpace(indent), String8(comment).string()); getIndentSpace(indent), cmt.string());
if (strstr(cmt.string(), "@deprecated") != NULL) {
deprecated = true;
}
} else if (sym.isPublic && !includePrivate) { } else if (sym.isPublic && !includePrivate) {
sym.sourcePos.warning("No comment for public symbol %s:%s/%s", sym.sourcePos.warning("No comment for public symbol %s:%s/%s",
assets->getPackage().string(), className.string(), assets->getPackage().string(), className.string(),
@ -1452,20 +1480,25 @@ static status_t writeSymbolClass(
} }
String16 typeComment(sym.typeComment); String16 typeComment(sym.typeComment);
if (typeComment.size() > 0) { if (typeComment.size() > 0) {
String8 cmt(typeComment);
if (!haveComment) { if (!haveComment) {
haveComment = true; haveComment = true;
fprintf(fp, fprintf(fp,
"%s/** %s\n", "%s/** %s\n", getIndentSpace(indent), cmt.string());
getIndentSpace(indent), String8(typeComment).string());
} else { } else {
fprintf(fp, fprintf(fp,
"%s %s\n", "%s %s\n", getIndentSpace(indent), cmt.string());
getIndentSpace(indent), String8(typeComment).string()); }
if (strstr(cmt.string(), "@deprecated") != NULL) {
deprecated = true;
} }
} }
if (haveComment) { if (haveComment) {
fprintf(fp,"%s */\n", getIndentSpace(indent)); fprintf(fp,"%s */\n", getIndentSpace(indent));
} }
if (deprecated) {
fprintf(fp, "%s@Deprecated\n", getIndentSpace(indent));
}
fprintf(fp, "%spublic static final int %s=0x%08x;\n", fprintf(fp, "%spublic static final int %s=0x%08x;\n",
getIndentSpace(indent), getIndentSpace(indent),
String8(name).string(), (int)sym.int32Val); String8(name).string(), (int)sym.int32Val);
@ -1484,17 +1517,25 @@ static status_t writeSymbolClass(
return UNKNOWN_ERROR; return UNKNOWN_ERROR;
} }
String16 comment(sym.comment); String16 comment(sym.comment);
bool deprecated = false;
if (comment.size() > 0) { if (comment.size() > 0) {
String8 cmt(comment);
fprintf(fp, fprintf(fp,
"%s/** %s\n" "%s/** %s\n"
"%s */\n", "%s */\n",
getIndentSpace(indent), String8(comment).string(), getIndentSpace(indent), cmt.string(),
getIndentSpace(indent)); getIndentSpace(indent));
if (strstr(cmt.string(), "@deprecated") != NULL) {
deprecated = true;
}
} else if (sym.isPublic && !includePrivate) { } else if (sym.isPublic && !includePrivate) {
sym.sourcePos.warning("No comment for public symbol %s:%s/%s", sym.sourcePos.warning("No comment for public symbol %s:%s/%s",
assets->getPackage().string(), className.string(), assets->getPackage().string(), className.string(),
String8(sym.name).string()); String8(sym.name).string());
} }
if (deprecated) {
fprintf(fp, "%s@Deprecated\n", getIndentSpace(indent));
}
fprintf(fp, "%spublic static final String %s=\"%s\";\n", fprintf(fp, "%spublic static final String %s=\"%s\";\n",
getIndentSpace(indent), getIndentSpace(indent),
String8(name).string(), sym.stringVal.string()); String8(name).string(), sym.stringVal.string());

View File

@ -960,7 +960,7 @@ public class WifiManager {
* *
* If this MulticastLock is not reference-counted, the first call to * If this MulticastLock is not reference-counted, the first call to
* {@code release} (after the radio was multicast locked using * {@code release} (after the radio was multicast locked using
* {@linke #acquire}) will unlock the multicast, and subsequent calls * {@link #acquire}) will unlock the multicast, and subsequent calls
* will be ignored. * will be ignored.
* *
* Note that if any other Wifi Multicast Locks are still outstanding * Note that if any other Wifi Multicast Locks are still outstanding