com.marklogic.io

## Class ResourcePool<K,R>

- java.lang.Object
- - com.marklogic.io.ResourcePool<K,R>

-     public class ResourcePool<K,R>
      extends java.lang.Object

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `protected static class` | `ResourcePool.PoolItem<R>`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `ResourcePool()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `closeExpired(long currTime)`
    `R` | `get(K key)`
    `protected long` | `getCurrentTime()`
    `boolean` | `isEmpty(K key)`
    `void` | `put(K key, R obj)`
    `void` | `put(K key, R resource, long expireTimeMillis)`
    `long` | `size(K key)`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### ResourcePool

          public ResourcePool()

  - ### Method Detail

    - #### isEmpty

          public boolean isEmpty(K key)

    - #### put

          public void put(K key,
                          R resource,
                          long expireTimeMillis)

    - #### put

          public void put(K key,
                          R obj)

    - #### get

          public R get(K key)

    - #### size

          public long size(K key)

    - #### getCurrentTime

          protected long getCurrentTime()

    - #### closeExpired

          public void closeExpired(long currTime)

Copyright © 2025 MarkLogic Corporation. All Rights Reserved.

Complete online documentation for MarkLogic Server, XQuery and related components may be found at developer.marklogic.com