BuildCacheServiceFactory (Gradle API 5.5-20190702033235+0000)
Date: 2019-07-01

Package org.gradle.caching

## Interface BuildCacheServiceFactory<T extends BuildCache>

- Type Parameters:
    `T` - the type of build cache configuration this factory can handle.

      public interface BuildCacheServiceFactory<T extends BuildCache>

  Factory interface to be provided by build cache service implementations.

  To be able to use a `BuildCacheService`, the factory that implements this interface and the configuration type (`BuildCache`) must be registered with the `BuildCacheConfiguration`.

  In settings.gradle:

           buildCache {
               // Register custom build cache implementation
               registerBuildCacheService(CustomBuildCache, CustomBuildCacheFactory)

               remote(CustomBuildCache) {
                   // configure custom build cache.
               }
           }

  Since:
    3.5

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Interface | Description
    --- | --- | ---
    `static interface` | `BuildCacheServiceFactory.Describer` | Builder-style object that allows build cache service factories to describe the cache service.

  - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `BuildCacheService` | `createBuildCacheService​(T configuration, BuildCacheServiceFactory.Describer describer)` | Creates a build cache service from the given configuration.

- - ### Method Detail

    - #### createBuildCacheService

          BuildCacheService createBuildCacheService​(T configuration,
                                                    BuildCacheServiceFactory.Describer describer)

      Creates a build cache service from the given configuration. Implementations should also provide a description via the given describer.