Class ReplaceRequest

    • Constructor Detail

      • ReplaceRequest

        public ReplaceRequest​(String key,
                              ByteBuf content,
                              String bucket)
        Creates a new ReplaceRequest.
        Parameters:
        key - the key of the document.
        content - the content of the document.
        bucket - the name of the bucket.
      • ReplaceRequest

        public ReplaceRequest​(String key,
                              ByteBuf content,
                              String bucket,
                              boolean json)
      • ReplaceRequest

        public ReplaceRequest​(String key,
                              ByteBuf content,
                              long cas,
                              String bucket)
        Creates a new ReplaceRequest.
        Parameters:
        key - the key of the document.
        content - the content of the document.
        cas - the cas value.
        bucket - the name of the bucket.
      • ReplaceRequest

        public ReplaceRequest​(String key,
                              ByteBuf content,
                              long cas,
                              String bucket,
                              boolean json)
      • ReplaceRequest

        public ReplaceRequest​(String key,
                              ByteBuf content,
                              long cas,
                              int exp,
                              int flags,
                              String bucket)
        Creates a new ReplaceRequest.
        Parameters:
        key - the key of the document.
        content - the content of the document.
        cas - the cas value.
        exp - the expiration time.
        flags - optional flags.
        bucket - the the name of the bucket.
      • ReplaceRequest

        public ReplaceRequest​(String key,
                              ByteBuf content,
                              long cas,
                              int exp,
                              int flags,
                              String bucket,
                              boolean json)
    • Method Detail

      • expiration

        public int expiration()
        Returns the expiration time for this document.
        Specified by:
        expiration in interface BinaryStoreRequest
        Returns:
        the expiration time.
      • flags

        public int flags()
        Returns the flags for this document.
        Specified by:
        flags in interface BinaryStoreRequest
        Returns:
        the flags.
      • cas

        public long cas()
        The CAS value of the request.
        Returns:
        the cas value.