lib/arborist/snmp.rb
changeset 8 e0b7c95a154f
child 17 e4f0fd44734d
equal deleted inserted replaced
7:4548e58c8c66 8:e0b7c95a154f
       
     1 # -*- ruby -*-
       
     2 #encoding: utf-8
       
     3 
       
     4 require 'loggability'
       
     5 require 'arborist'
       
     6 
       
     7 
       
     8 # Various monitoring checks using SNMP, for the Arborist monitoring toolkit.
       
     9 module Arborist::SNMP
       
    10 	extend Loggability
       
    11 
       
    12 	# Loggability API -- set up a log host for this library
       
    13 	log_as :arborist_snmp
       
    14 
       
    15 
       
    16 	# Package version
       
    17 	VERSION = '0.4.0'
       
    18 
       
    19 	# Version control revision
       
    20 	REVISION = %q$Revision$
       
    21 
       
    22 
       
    23 	### Return the name of the library with the version, and optionally the build ID if
       
    24 	### +include_build+ is true.
       
    25 	def self::version_string( include_build: false )
       
    26 		str = "%p v%s" % [ self, VERSION ]
       
    27 		str << ' (' << REVISION.strip << ')' if include_build
       
    28 		return str
       
    29 	end
       
    30 
       
    31 
       
    32 	require 'arborist/monitor/snmp'
       
    33 
       
    34 end # module Arborist::SNMP
       
    35