Interface Storage

All Superinterfaces:
Serializable

public interface Storage extends Serializable
A storage interface is used for ZK web application to store application data with a string key and a data type value. The implementation class for this interface must be a thread safe that application developer can add, remove, or get the data without dealing with threads.
Since:
8.0.0
Author:
jumperchen
  • Method Summary

    Modifier and Type
    Method
    Description
    <T> T
    Returns the value from the given key.
    <T> T
    Removes the value from the given key, if any.
    <T> void
    setItem(String key, T value)
    Sets a data value with a given key
  • Method Details

    • getItem

      <T> T getItem(String key)
      Returns the value from the given key.
    • setItem

      <T> void setItem(String key, T value)
      Sets a data value with a given key
    • removeItem

      <T> T removeItem(String key)
      Removes the value from the given key, if any.
      Returns:
      a removed value or null