package netsnmp

  1. Overview
  2. Docs
An interface to the Net-SNMP client library

Install

Dune Dependency

Authors

Maintainers

Sources

v0.17.0.tar.gz
sha256=f300b9773b47da231c63fd272e171011fc19c79438dd0f18415f59c962f402d2

doc/src/netsnmp.raw/netsnmp_exceptions.ml.html

Source file netsnmp_exceptions.ml

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
exception Not_found of string
exception System_error of string
exception Out_of_memory
exception Response_error of (Pdu_error.t * string)
exception General_error of (int * Netsnmp_error.t * string)

(* os_err, snmp_error, error_string *)
exception Request_timeout

let () =
  Callback.register_exception "Netsnmp_error_not_found" (Not_found "");
  Callback.register_exception "Netsnmp_error_system" (System_error "");
  Callback.register_exception "Netsnmp_out_of_memory" Out_of_memory;
  Callback.register_exception
    "Netsnmp_response_error"
    (Response_error (Pdu_error.SNMP_ERR_NOERROR, ""));
  Callback.register_exception
    "Netsnmp_general_error"
    (General_error (0, Netsnmp_error.SNMPERR_SUCCESS, ""));
  Callback.register_exception "Netsnmp_request_timeout" Request_timeout
;;
OCaml

Innovation. Community. Security.