You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The parser doesn't support parsing of custom flags in VALUE responses from the server. We should expose and API that allows users to specify a custom flag parser.
Specification
The parser exposes an flag api which accepts 2 arguments
a unsigned 16/32bit integer
a parser function
The integer can be 16 or 32 bit, this depends on the memcached version people are running.
Memcached 1.2.0 and lower the flag is a 16-bit integer. In memcached 1.2.1 and higher the flag is a 32-bit integer. So it's up to the developer to select correct flag.
The parser function receives a Buffer instance and returns the parsed value immediately.
// This will parse the responseparser.flag(1,function(buffer){returnNumber(buffer.toString());});
TODO
Check if we should also supply a string representation of the buffer to the parser.
The text was updated successfully, but these errors were encountered:
The parser doesn't support parsing of custom
flags
inVALUE
responses from the server. We should expose and API that allows users to specify a custom flag parser.Specification
The parser exposes an
flag
api which accepts 2 argumentsThe integer can be 16 or 32 bit, this depends on the memcached version people are running.
Memcached 1.2.0 and lower the flag is a 16-bit integer. In memcached 1.2.1 and higher the flag is a 32-bit integer. So it's up to the developer to select correct flag.
The parser function receives a
Buffer
instance and returns the parsed value immediately.TODO
The text was updated successfully, but these errors were encountered: