Gjsify LogoGjsify Logo

Hierarchy

Index

Properties

enable_logging?: boolean

%TRUE if network traffic should be logged to a trace file (specified by calling uhm_server_start_trace()). This operates independently of whether traffic is online or being handled locally by the mock server. Use this in conjunction with #UhmServer:enable-online to either log online traffic, or replay logged traffic locally.

enable_online?: boolean

%TRUE if network traffic should reach the Internet as normal; %FALSE to redirect it to the local mock server. Use this in conjunction with #UhmServer:enable-logging to either log online traffic, or replay logged traffic locally.

tls_certificate?: TlsCertificate

TLS certificate for the mock server to use when serving HTTPS pages. If this is non-%NULL, the server will always use HTTPS. If it is %NULL, the server will always use HTTP. The TLS certificate may be changed after constructing the #UhmServer, but changes to the property will not take effect until the next call to uhm_server_run().

A certificate and private key may be generated by executing: openssl req -x509 -newkey rsa:2048 -keyout key.pem -out cert.pem -nodes. These files may then be used to construct a #GTlsCertificate by calling g_tls_certificate_new_from_files().

Alternatively, a default #GTlsCertificate which wraps a dummy certificate (not signed by any certificate authority) may be set by calling uhm_server_set_default_tls_certificate(). This may be used as the #UhmServer:tls-certificate if the code under test has no specific requirements of the certificate used by the mock server it's tested against.

trace_directory?: Gio.File

Directory relative to which all trace files specified in calls to uhm_server_start_trace() will be resolved. This is not used for any other methods, but must be non-%NULL if uhm_server_start_trace() is called.

Legend

  • Module
  • Object literal
  • Variable
  • Function
  • Function with type parameter
  • Index signature
  • Type alias
  • Type alias with type parameter
  • Enumeration
  • Enumeration member
  • Property
  • Method
  • Interface
  • Interface with type parameter
  • Constructor
  • Property
  • Method
  • Index signature
  • Class
  • Class with type parameter
  • Constructor
  • Property
  • Method
  • Accessor
  • Index signature
  • Inherited constructor
  • Inherited property
  • Inherited method
  • Inherited accessor
  • Protected property
  • Protected method
  • Protected accessor
  • Private property
  • Private method
  • Private accessor
  • Static property
  • Static method