Sourcemeta Core 0.0.0
Loading...
Searching...
No Matches
markdown.h
1#ifndef SOURCEMETA_CORE_MARKDOWN_H_
2#define SOURCEMETA_CORE_MARKDOWN_H_
3
4#ifndef SOURCEMETA_CORE_MARKDOWN_EXPORT
5#include <sourcemeta/core/markdown_export.h>
6#endif
7
8// NOLINTBEGIN(misc-include-cleaner)
9#include <sourcemeta/core/markdown_error.h>
10// NOLINTEND(misc-include-cleaner)
11
12#include <cstddef> // std::size_t
13#include <cstdint> // std::uint32_t
14#include <limits> // std::numeric_limits
15#include <string> // std::string
16#include <string_view> // std::string_view
17
27
28namespace sourcemeta::core {
29
34inline constexpr std::size_t MARKDOWN_MAXIMUM_INPUT_BYTES{
35 std::numeric_limits<std::uint32_t>::max()};
36
61SOURCEMETA_CORE_MARKDOWN_EXPORT
62auto markdown_to_html(const std::string_view input, const bool safe = true,
63 std::size_t maximum_input_bytes =
64 MARKDOWN_MAXIMUM_INPUT_BYTES) -> std::string;
65
66} // namespace sourcemeta::core
67
68#endif
SOURCEMETA_CORE_MARKDOWN_EXPORT auto markdown_to_html(const std::string_view input, const bool safe=true, std::size_t maximum_input_bytes=MARKDOWN_MAXIMUM_INPUT_BYTES) -> std::string
constexpr std::size_t MARKDOWN_MAXIMUM_INPUT_BYTES
Definition markdown.h:34