Interface SyncStreamingCache<K>


public interface SyncStreamingCache<K>
SyncStreamingCache implements streaming versions of most SyncCache methods
Since:
14.0
  • Method Details

    • get

      default <T extends InputStream & CacheEntryMetadata> T get(K key)
      Retrieves the value of the specified key as an InputStream. It is up to the application to ensure that the stream is consumed and closed. The marshaller is ignored, i.e. all data will be read in its raw binary form. The returned input stream implements the CacheEntryMetadata interface. The returned input stream is not thread-safe.
      Parameters:
      key - key to use
    • get

      <T extends InputStream & CacheEntryMetadata> T get(K key, CacheOptions options)
      Retrieves the value of the specified key as an InputStream. It is up to the application to ensure that the stream is consumed and closed. The marshaller is ignored, i.e. all data will be read in its raw binary form. The returned input stream implements the CacheEntryMetadata interface. The returned input stream is not thread-safe.
      Parameters:
      key - key to use
    • put

      default OutputStream put(K key)
      Initiates a streaming put operation. It is up to the application to write to the returned OutputStream and close it when there is no more data to write. The marshaller is ignored, i.e. all data will be written in its raw binary form. The returned output stream is not thread-safe.
      Parameters:
      key - key to use
    • put

      OutputStream put(K key, CacheOptions options)
      Parameters:
      key -
      options -
      Returns:
    • putIfAbsent

      default OutputStream putIfAbsent(K key)
      A conditional form of put which inserts an entry into the cache only if no mapping for the key is already present. The operation is atomic. The server only performs the operation once the stream has been closed. The returned output stream is not thread-safe.
      Parameters:
      key - key to use
    • putIfAbsent

      OutputStream putIfAbsent(K key, CacheWriteOptions options)
      Parameters:
      key -
      options -
      Returns: