Class JPAStorageRecord<T>

    • Field Detail

      • CONTEXT_SIZE

        public static final int CONTEXT_SIZE
        Length of the context column.
        See Also:
        Constant Field Values
      • context

        private String context
        Context string.
      • key

        private String key
        Key string.
    • Constructor Detail

      • JPAStorageRecord

        public JPAStorageRecord()
        Creates a new JPA storage record. All properties initialized to null.
    • Method Detail

      • getContext

        @Nonnull
        public String getContext()
        Returns the context.
        Returns:
        context
      • setContext

        public void setContext​(@Nonnull @NotEmpty
                               String ctx)
        Sets the context.
        Parameters:
        ctx - to set
      • getKey

        @Nonnull
        public String getKey()
        Returns the key.
        Returns:
        key
      • setKey

        public void setKey​(@Nonnull @NotEmpty
                           String k)
        Sets the key.
        Parameters:
        k - to set
      • getValue

        @Nonnull
        public String getValue()
        Get the record value.
        Overrides:
        getValue in class StorageRecord<T>
        Returns:
        the record value
      • getExpiration

        @Nullable
        public Long getExpiration()
        Get the record expiration.
        Overrides:
        getExpiration in class StorageRecord<T>
        Returns:
        the record expiration, or null if none
      • getVersion

        public long getVersion()
        Get the record version.
        Overrides:
        getVersion in class StorageRecord<T>
        Returns:
        the record version
      • resetVersion

        public void resetVersion()
        Resets the version of this storage record to 1.