Sha256: fca60d39d768eaf983f87245d12203771d8203ca3368603d3b4fc27d11ddcb44
Contents?: true
Size: 506 Bytes
Versions: 4
Compression:
Stored size: 506 Bytes
Contents
class Snmpjr class Response attr_reader :error, :oid def initialize response = {} @error = response[:error] || '' @value = response[:value] || '' @oid = response[:oid] || '' end def error? if @error.empty? false else true end end def to_s @value end def ==(other) return false unless other.instance_of?(self.class) @error == other.error && to_s == other.to_s && @oid == other.oid end end end
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
snmpjr-0.3.2-java | lib/snmpjr/response.rb |
snmpjr-0.3.1-java | lib/snmpjr/response.rb |
snmpjr-0.3.0-java | lib/snmpjr/response.rb |
snmpjr-0.2.2-java | lib/snmpjr/response.rb |