A crate exposing the
pact APIs to other languages
via a C Foreign Function Interface.
Tools for FFI error reporting and handling.
Sets up a log sink to view logs from the FFI.
mock_server module provides a number of exported functions using C bindings for
controlling a mock server. These can be used in any language that supports C bindings.
Represents messages in
plugins module provides exported functions using C bindings for using plugins with
verifier module provides a number of exported functions using C bindings for
controlling the pact verification process. These can be used in any language that supports C bindings.
Get a mutable reference from a raw pointer
Get an immutable reference from a raw pointer
Construct a CStr safely with null checks.
&str safely with null checks.
A collection of mismatches from a matching comparison.
An iterator over mismatches.
Enum that defines the different types of mismatches that can occur.
Enable ANSI coloured output on Windows. On non-Windows platforms, this function is a no-op.
Initialise the mock server library, can provide an environment variable name to use to set the log levels. This function should only be called once, as it tries to install a global tracing subscriber.
Initialises logging, and sets the log level explicitly. This function should only be called once, as it tries to install a global tracing subscriber.
Match a pair of messages, producing a collection of mismatches, which is empty if the two messages matched.
Get an ANSI-compatible description of a mismatch.
Get a description of a mismatch.
Get a summary of a mismatch.
Get a JSON representation of the mismatch.
Get the type of a mismatch.
Get an iterator over mismatches.
Delete a mismatches iterator when you’re done with it.
Get the next mismatch from a mismatches iterator.
Returns the current library version