# The language to output bindings in
language = "C"

# An optional string of text to output between major sections of the generated
# file as a warning against manual editing
autogen_warning = "/* Don't modify this file manually. It is autogenerated by cbindgen. */"

# An optional name to use as an include guard
include_guard = "_TQUIC_H_"

# Whether to make a C header C++ compatible.
cpp_compat = true

# Include doc comments from Rust as documentation
documentation = true

# A list of headers to #include (with quotes)
sys_includes = ["sys/socket.h", "sys/types.h"]

[export]
exclude = ["MAX_CID_LEN", "MIN_CLIENT_INITIAL_LEN"]

[export.rename]
"Config" = "quic_config_t"
"TlsConfig" = "quic_tls_config_t"
"SslCtx" = "SSL_CTX"
"Connection" = "quic_conn_t"
"Endpoint" = "quic_endpoint_t"
"PacketOutSpec" = "quic_packet_out_spec_t"
"PacketInfo" = "quic_packet_info_t"
"PathAddress" = "quic_path_address_t"
"FourTupleIter" = "quic_path_address_iter_t"
"Shutdown" = "quic_shutdown"
"TransportHandler" = "quic_transport_handler_t"
"TransportMethods" = "quic_transport_methods_t"
"TransportContext" = "quic_transport_context_t"
"PacketSendHandler" = "quic_packet_send_handler_t"
"PacketSendMethods" = "quic_packet_send_methods_t"
"PacketSendContext" = "quic_packet_send_context_t"
"TlsConfigSelectMethods" = "quic_tls_config_select_methods_t"
"TlsConfigSelectorContext" = "quic_tls_config_select_context_t"
"CongestionControlAlgorithm" = "quic_congestion_control_algorithm"
"LevelFilter" = "quic_log_level"
"Http3Connection" = "http3_conn_t"
"Http3Config" = "http3_config_t"
"Http3Context" = "http3_context_t"
"Http3Handler" = "http3_handler_t"
"Http3Headers" = "http3_headers_t"
"Http3Methods" = "http3_methods_t"
"Http3Priority" = "http3_priority_t"
"Header" = "http3_header_t"
"iovec" = "struct iovec"
"sockaddr" = "struct sockaddr"
"sockaddr_storage" = "struct sockaddr_storage"

[enum]
rename_variants = "QualifiedScreamingSnakeCase"

[parse]
parse_deps = true
include = ["libc"]
