Class ConvertCacheDescriptor

java.lang.Object
org.nuxeo.ecm.core.convert.extension.ConvertCacheDescriptor
All Implemented Interfaces:
Descriptor

public class ConvertCacheDescriptor extends Object implements Descriptor
Since:
2025.0
  • Field Details

    • DEFAULT_CACHE_ENABLED

      public static final boolean DEFAULT_CACHE_ENABLED
      See Also:
    • DEFAULT_CACHING_DIRECTORY

      public static final String DEFAULT_CACHING_DIRECTORY
      See Also:
    • DEFAULT_GC_RATE

      public static final Duration DEFAULT_GC_RATE
    • DEFAULT_DISK_CACHE_IN_KB

      public static final long DEFAULT_DISK_CACHE_IN_KB
      See Also:
    • enabled

      protected Boolean enabled
    • directory

      protected String directory
    • gcRate

      protected Duration gcRate
      The rate to run the GC.
    • maxSizeKB

      protected Long maxSizeKB
      The maximum size (in KB) to reach to run the GC.

      Use a negative value to clear the cache on each GC run.

  • Constructor Details

    • ConvertCacheDescriptor

      public ConvertCacheDescriptor()
  • Method Details

    • getId

      public String getId()
      Description copied from interface: Descriptor
      The descriptor id, descriptors with same id are merged.

      To forbid multiple descriptors use UNIQUE_DESCRIPTOR_ID.

      To forbid merge use a unique value, non-overriden toString() for exemple.

      Specified by:
      getId in interface Descriptor
    • isEnabled

      public boolean isEnabled()
    • getDirectory

      public Path getDirectory()
    • getGcRate

      public Duration getGcRate()
    • getMaxSizeKB

      public long getMaxSizeKB()
    • merge

      public Descriptor merge(Descriptor o)
      Description copied from interface: Descriptor
      Returns a descriptor representing other merged into this

      Default implementation returns other.

      Specified by:
      merge in interface Descriptor
      Returns:
      the merged descriptor