• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# basic_json::operator""_json_pointer
2
3```cpp
4json_pointer operator "" _json_pointer(const char* s, std::size_t n)
5```
6
7This operator implements a user-defined string literal for JSON Pointers. It can be used by adding `#!cpp _json_pointer`
8to a string literal and returns a [`json_pointer`](../json_pointer.md) object if no parse error occurred.
9
10## Parameters
11
12`s` (in)
13:   a string representation of a JSON Pointer
14
15`n` (in)
16:   length of string `s`
17
18## Return value
19
20[`json_pointer`](../json_pointer.md) value parsed from `s`
21
22## Exceptions
23
24The function can throw anything that [`json_pointer::json_pointer`](../json_pointer.md) would throw.
25
26## Complexity
27
28Linear.
29
30## Version history
31
32- Added in version 2.0.0.
33