Added in API level 16

TargetApi


public abstract @interface TargetApi
implements Annotation

android.annotation.TargetApi


Indicates that Lint should treat this type as targeting a given API level, no matter what the project target is.

Summary

Public methods

int value()

This sets the target api level for the type..

Inherited methods

abstract Class<? extends Annotation> annotationType()

Returns the annotation interface of this annotation.

abstract boolean equals(Object obj)

Returns true if the specified object represents an annotation that is logically equivalent to this one.

abstract int hashCode()

Returns the hash code of this annotation.

abstract String toString()

Returns a string representation of this annotation.

Public methods

value

Added in API level 16
public int value ()

This sets the target api level for the type..

Returns
int