Package: groovy.lang

## [Java] Annotation Type GrabResolver

- groovy.lang.GrabResolver

- Used to add a repository for resolving Grape dependencies.

  For example:

       @GrabResolver(name='restlet.org', root='http://maven.restlet.org')
       @Grab(group='org.restlet', module='org.restlet', version='1.1.6')
       class MyRestlet extends org.restlet.Restlet {
         // ...
       }

  By default, the Grapes subsystem uses an Ivy chained resolver. Each resolver added using `@GrabResolver` is appended to the chain. By default, the grape subsystem is shared globally, so added resolvers will become available for any subsequent grab calls. Dependency resolution follows Ivy's artifact resolution which tries to resolve artifacts in the order specified in the chain of resolvers.

  Further information about customising grape behavior can be found on the Grape documentation page: http://groovy.codehaus.org/Grape.

  Authors:
    Merlyn Albery-Speyer

- - ### Element Summary

    Required Element Summary
    Type | Name and Description
    --- | ---
    `String` | `name`
    `String` | `root`

    Optional Element Summary
    Type | Name and Description
    --- | ---
    `boolean` | `initClass` By default, when a `@GrabResolver` annotation is used, a `Grape.addResolver()` call is added to the static initializers of the class the annotatable node appears in.
    `boolean` | `m2Compatible` @default true
    `String` | `value` @default ""

  - ### Inherited Methods Summary

    Inherited Methods
    Methods inherited from class | Name
    --- | ---
    `class Object` | `wait, wait, wait, equals, toString, hashCode, getClass, notify, notifyAll`

- - ### Element Detail

    - #### public boolean initClass

      By default, when a `@GrabResolver` annotation is used, a `Grape.addResolver()` call is added to the static initializers of the class the annotatable node appears in. If you wish to disable this, add `initClass=false` to the annotation. @default true

    - #### public boolean m2Compatible

      @default true

    - #### public String name

    - #### public String root

    - #### public String value

      @default ""