These functions and macros may be used to conditionally compile features depending on the version of the library being used.
They may also be used to employ various features at runtime and to retrieve the version for informational purposes.
const char* lcb_get_version |
( |
lcb_U32 * |
version | ) |
|
Get the version of the library.
- Parameters
-
version | where to store the numeric representation of the version (or NULL if you don't care) |
- Returns
- the textual description of the version ('\0' terminated). Do not try to release this string.
int lcb_supports_feature |
( |
int |
n | ) |
|
- Stability
- Committed:
- Determine if this version has support for a particularl feature
- Parameters
-
n | the feature ID to check for |
- Returns
- 0 if not supported, nonzero if supported.
libcouchbase hex version
This number contains the hexadecimal representation of the library version. It is in a format of 0xXXYYZZ
where XX
is the two digit major version (e.g. 02
), YY
is the minor version (e.g. 05
) and ZZ
is the patch version (e.g. 24
).
For example:
String | Hex |
2.0.0 | 0x020000 |
2.1.3 | 0x020103 |
3.0.15 | 0x030015 |
#define LCB_VERSION_CHANGESET |