semver: 1.0 -> 1
[m6w6/libmemcached] / include / libmemcached-1 / types / return.h
1 /*
2 +--------------------------------------------------------------------+
3 | libmemcached - C/C++ Client Library for memcached |
4 +--------------------------------------------------------------------+
5 | Redistribution and use in source and binary forms, with or without |
6 | modification, are permitted under the terms of the BSD license. |
7 | You should have received a copy of the license in a bundled file |
8 | named LICENSE; in case you did not receive a copy you can review |
9 | the terms online at: https://opensource.org/licenses/BSD-3-Clause |
10 +--------------------------------------------------------------------+
11 | Copyright (c) 2006-2014 Brian Aker https://datadifferential.com/ |
12 | Copyright (c) 2020 Michael Wallner <mike@php.net> |
13 +--------------------------------------------------------------------+
14 */
15
16 #pragma once
17
18 enum memcached_return_t {
19 MEMCACHED_SUCCESS,
20 MEMCACHED_FAILURE,
21 MEMCACHED_HOST_LOOKUP_FAILURE, // getaddrinfo() and getnameinfo() only
22 MEMCACHED_CONNECTION_FAILURE,
23 MEMCACHED_CONNECTION_BIND_FAILURE, // DEPRECATED, see MEMCACHED_HOST_LOOKUP_FAILURE
24 MEMCACHED_WRITE_FAILURE,
25 MEMCACHED_READ_FAILURE,
26 MEMCACHED_UNKNOWN_READ_FAILURE,
27 MEMCACHED_PROTOCOL_ERROR,
28 MEMCACHED_CLIENT_ERROR,
29 MEMCACHED_SERVER_ERROR, // Server returns "SERVER_ERROR"
30 MEMCACHED_ERROR, // Server returns "ERROR"
31 MEMCACHED_DATA_EXISTS,
32 MEMCACHED_DATA_DOES_NOT_EXIST,
33 MEMCACHED_NOTSTORED,
34 MEMCACHED_STORED,
35 MEMCACHED_NOTFOUND,
36 MEMCACHED_MEMORY_ALLOCATION_FAILURE,
37 MEMCACHED_PARTIAL_READ,
38 MEMCACHED_SOME_ERRORS,
39 MEMCACHED_NO_SERVERS,
40 MEMCACHED_END,
41 MEMCACHED_DELETED,
42 MEMCACHED_VALUE,
43 MEMCACHED_STAT,
44 MEMCACHED_ITEM,
45 MEMCACHED_ERRNO,
46 MEMCACHED_FAIL_UNIX_SOCKET, // DEPRECATED
47 MEMCACHED_NOT_SUPPORTED,
48 MEMCACHED_NO_KEY_PROVIDED, /* Deprecated. Use MEMCACHED_BAD_KEY_PROVIDED! */
49 MEMCACHED_FETCH_NOTFINISHED,
50 MEMCACHED_TIMEOUT,
51 MEMCACHED_BUFFERED,
52 MEMCACHED_BAD_KEY_PROVIDED,
53 MEMCACHED_INVALID_HOST_PROTOCOL,
54 MEMCACHED_SERVER_MARKED_DEAD,
55 MEMCACHED_UNKNOWN_STAT_KEY,
56 MEMCACHED_E2BIG,
57 MEMCACHED_INVALID_ARGUMENTS,
58 MEMCACHED_KEY_TOO_BIG,
59 MEMCACHED_AUTH_PROBLEM,
60 MEMCACHED_AUTH_FAILURE,
61 MEMCACHED_AUTH_CONTINUE,
62 MEMCACHED_PARSE_ERROR,
63 MEMCACHED_PARSE_USER_ERROR,
64 MEMCACHED_DEPRECATED,
65 MEMCACHED_IN_PROGRESS,
66 MEMCACHED_SERVER_TEMPORARILY_DISABLED,
67 MEMCACHED_SERVER_MEMORY_ALLOCATION_FAILURE,
68 MEMCACHED_MAXIMUM_RETURN, /* Always add new error code before */
69 MEMCACHED_CONNECTION_SOCKET_CREATE_FAILURE = MEMCACHED_ERROR
70 };
71
72 #ifndef __cplusplus
73 typedef enum memcached_return_t memcached_return_t;
74 #endif