# Classpath

@Documented
@Retention(value = RetentionPolicy.RUNTIME)
@Target(value = [ElementType.METHOD, ElementType.FIELD])
annotation class Classpath(source)

Marks a property as specifying a JVM classpath for a task.

This annotation should be attached to the getter method in Java or the property in Groovy. Annotations on setters or just the field in Java are ignored.

For jar files, the normalized path is empty. The content of the jar file is normalized so that time stamps and order of the zip entries in the jar file do not matter. This normalization applies to not only files directly on the classpath, but also to any jar files found inside directories or nested inside other jar files. If a directory is a classpath entry, then the root directory itself is ignored. The files in the directory are sorted and the relative path to the root directory is used as normalized path.

Note: to stay compatible with versions prior to Gradle 3.2, classpath properties need to be annotated with @InputFiles as well.

#### Since

3.2

## Functions

annotationType
Link copied to clipboard
abstract fun annotationType(): Class<out Annotation>
equals
Link copied to clipboard
abstract fun equals(p: Any): Boolean
hashCode
Link copied to clipboard
abstract fun hashCode(): Int
toString
Link copied to clipboard
abstract fun toString(): String