IDeprecated Interface
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
A program element annotated @Deprecated
is one that programmers
are discouraged from using.
[Android.Runtime.Register("java/lang/Deprecated", "", "Java.Lang.IDeprecatedInvoker")]
public interface IDeprecated : IDisposable, Java.Interop.IJavaPeerable, Java.Lang.Annotation.IAnnotation
[<Android.Runtime.Register("java/lang/Deprecated", "", "Java.Lang.IDeprecatedInvoker")>]
type IDeprecated = interface
interface IAnnotation
interface IJavaObject
interface IDisposable
interface IJavaPeerable
- Attributes
- Implements
Remarks
A program element annotated @Deprecated
is one that programmers are discouraged from using. An element may be deprecated for any of several reasons, for example, its usage is likely to lead to errors; it may be changed incompatibly or removed in a future version; it has been superseded by a newer, usually preferable alternative; or it is obsolete.
Compilers issue warnings when a deprecated program element is used or overridden in non-deprecated code. Use of the @Deprecated
annotation on a local variable declaration or on a parameter declaration or a package declaration has no effect on the warnings issued by a compiler.
When a module is deprecated, the use of that module in requires
, but not in exports
or opens
clauses causes a warning to be issued. A module being deprecated does <em>not</em> cause warnings to be issued for uses of types within the module.
This annotation type has a string-valued element since
. The value of this element indicates the version in which the annotated program element was first deprecated.
This annotation type has a boolean-valued element forRemoval
. A value of true
indicates intent to remove the annotated program element in a future version. A value of false
indicates that use of the annotated program element is discouraged, but at the time the program element was annotated, there was no specific intent to remove it.
Added in 1.5.
Java documentation for java.lang.Deprecated
.
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.
Properties
Handle |
Gets the JNI value of the underlying Android object. (Inherited from IJavaObject) |
JniIdentityHashCode |
Returns the value of |
JniManagedPeerState |
State of the managed peer. (Inherited from IJavaPeerable) |
JniPeerMembers |
Member access and invocation support. (Inherited from IJavaPeerable) |
PeerReference |
Returns a JniObjectReference of the wrapped Java object instance. (Inherited from IJavaPeerable) |
Methods
AnnotationType() |
Returns the annotation interface of this annotation. (Inherited from IAnnotation) |
Disposed() |
Called when the instance has been disposed. (Inherited from IJavaPeerable) |
DisposeUnlessReferenced() |
If there are no outstanding references to this instance, then
calls |
Equals(Object) |
Returns true if the specified object represents an annotation that is logically equivalent to this one. (Inherited from IAnnotation) |
Finalized() |
Called when the instance has been finalized. (Inherited from IJavaPeerable) |
ForRemoval() |
Indicates whether the annotated element is subject to removal in a future version. |
GetHashCode() |
Returns the hash code of this annotation. (Inherited from IAnnotation) |
SetJniIdentityHashCode(Int32) |
Set the value returned by |
SetJniManagedPeerState(JniManagedPeerStates) | (Inherited from IJavaPeerable) |
SetPeerReference(JniObjectReference) |
Set the value returned by |
Since() |
Returns the version in which the annotated element became deprecated. |
ToString() |
Returns a string representation of this annotation. (Inherited from IAnnotation) |
UnregisterFromRuntime() |
Unregister this instance so that the runtime will not return it from future Java.Interop.JniRuntime+JniValueManager.PeekValue invocations. (Inherited from IJavaPeerable) |
Extension Methods
JavaCast<TResult>(IJavaObject) |
Performs an Android runtime-checked type conversion. |
JavaCast<TResult>(IJavaObject) | |
GetJniTypeName(IJavaPeerable) |