RPNXCortado
C++23 JVM class-file, bytecode, validation, and JAR toolkit
Loading...
Searching...
No Matches
class_file.hpp File Reference

Class-file serialization, deserialization, and iterator adapters. More...

#include <cstddef>
#include <iterator>
#include <rpnx/cortado/attributes.hpp>
#include <rpnx/cortado/errors.hpp>
#include <rpnx/cortado/validation.hpp>
#include <span>
#include <stdexcept>
#include <utility>
#include <vector>

Go to the source code of this file.

Classes

struct  rpnx::cortado::class_file_read_options
 Resource and strictness controls for class-file decoding. More...
 
struct  rpnx::cortado::class_file_write_options
 Strictness controls for class-file encoding. More...
 
struct  rpnx::cortado::deserialization_result< T >
 A decoded value and the number of source bytes it consumed. More...
 

Namespaces

namespace  rpnx::cortado
 JVM class-file, bytecode, validation, generation, and JAR APIs.
 

Functions

std::vector< std::byte > rpnx::cortado::serialize_class_file (class_file const &value, class_file_write_options const &options={})
 Serializes a class file using the big-endian JVM class-file format.
 
class_file rpnx::cortado::deserialize_class_file (std::span< std::byte const > bytes, class_file_read_options const &options={})
 Deserializes exactly one class file and rejects trailing bytes.
 
deserialization_result< class_filerpnx::cortado::deserialize_class_file_prefix (std::span< std::byte const > bytes, class_file_read_options const &options={})
 Deserializes one class file prefix and reports the number of bytes consumed.
 
template<typename OutputIt>
auto rpnx::cortado::serialize_iter (class_file const &value, OutputIt output, class_file_write_options const &options={}) -> OutputIt
 Serial4-style output-iterator interface for JVM class-file bytes.
 
template<typename OutputIt>
auto rpnx::cortado::serialize_iter (class_file const &value, OutputIt output, OutputIt end, class_file_write_options const &options={}) -> OutputIt
 Serial4-style bounded output-iterator interface for JVM class-file bytes.
 
template<std::forward_iterator InputIt, std::sentinel_for< InputIt > Sentinel>
auto rpnx::cortado::deserialize_iter (class_file &value, InputIt input, Sentinel end, class_file_read_options const &options={}) -> InputIt
 Serial4-style bounded forward-iterator interface for JVM class-file bytes.
 

Detailed Description

Class-file serialization, deserialization, and iterator adapters.

Definition in file class_file.hpp.