Nasza ocena:

Wyświetleń: 462
Komentarze: 0

Pobierz ten dokument za darmo

Podgląd dokumentu
Increment-opracowanie - strona 1

Fragment notatki:

Increment/Decrement: incr, decr
The increment and decrement commands change the value of a key within the server without
performing a separate get/set sequence. The operations assume that the currently stored value is a
64-bit integer. If the stored value is not a 64-bit integer, then the value is assumed to be zero before
the increment or decrement operation is applied.
Increment and decrement commands take the form:
incr key value [noreply]
decr key value [noreply]
• key: The key name.
• value: An integer to be used as the increment or decrement value.
• noreply: Tells the server not to reply to the command.
The response is:
• NOT_FOUND: The specified key could not be located.
• value: The new value associated with the specified key.
Values are assumed to be unsigned. For decr operations, the value is never decremented below 0.
For incr operations, the value wraps around the 64-bit maximum.
... zobacz całą notatkę

Komentarze użytkowników (0)

Zaloguj się, aby dodać komentarz