Skip to main content

Module json_path_util

Module json_path_util 

Source
Expand description

Filesystem helpers for resolving URL paths onto JSON-compatible files.

§Why these live in server, not routing

Pre-5.0 these sat alongside json_value_by_jsonpath in core::util::json. But resolve_with_json_compatible_extensions and is_equivalent_json_file both touch the filesystem to answer “does this path exist as a file?”. That’s a server-layer activity — the routing layer stays abstract and doesn’t care where bytes come from — so they moved here in 5.0.

Constants§

ROOT_DIRECTORY_FILE_NAME
Directory index filename (same spirit as index.html).

Functions§

resolve_with_json_compatible_extensions
Try to resolve a user-visible URL path onto a real file on disk.