SnmpKit.SnmpLib.MIB.SnmpTokenizer (snmpkit v0.6.3)
True 1:1 Elixir port of Erlang SNMP tokenizer (snmpc_tok.erl).
This is a direct translation of the official Erlang SNMP tokenizer from OTP lib/snmp/src/compile/snmpc_tok.erl
Original copyright: Ericsson AB 1996-2025 (Apache License 2.0)
Summary
Functions
Returns a specification to start this module under a supervisor.
Format error message. Equivalent to snmpc_tok:format_error/1
Get all remaining tokens. Equivalent to snmpc_tok:get_all_tokens/1
Get next token from tokenizer. Equivalent to snmpc_tok:get_token/1
Null get_line function. Equivalent to snmpc_tok:null_get_line/0
Start tokenizer gen_server. Equivalent to snmpc_tok:start_link/2
Stop tokenizer. Equivalent to snmpc_tok:stop/1
Test function. Equivalent to snmpc_tok:test/0
Tokenize a string directly. Equivalent to snmpc_tok:tokenize/2
Types
@type state() :: %SnmpKit.SnmpLib.MIB.SnmpTokenizer{ chars: charlist(), get_line_fun: function() | nil, line: pos_integer() }
@type token() :: {atom(), any(), pos_integer()}
Functions
Returns a specification to start this module under a supervisor.
See Supervisor
.
Format error message. Equivalent to snmpc_tok:format_error/1
Get all remaining tokens. Equivalent to snmpc_tok:get_all_tokens/1
Get next token from tokenizer. Equivalent to snmpc_tok:get_token/1
@spec null_get_line() :: :eof
Null get_line function. Equivalent to snmpc_tok:null_get_line/0
Start tokenizer gen_server. Equivalent to snmpc_tok:start_link/2
@spec stop(pid()) :: :ok
Stop tokenizer. Equivalent to snmpc_tok:stop/1
Test function. Equivalent to snmpc_tok:test/0
Tokenize a string directly. Equivalent to snmpc_tok:tokenize/2