Class: LittleneckClamAV::Result

Inherits:
Object
  • Object
show all
Defined in:
lib/littleneck_clamav/result.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(opts) ⇒ Result

Returns a new instance of Result.



3
4
5
6
7
# File 'lib/littleneck_clamav/result.rb', line 3

def initialize(opts)
  @path        = opts[:path]
  @clean       = opts[:clean]
  @description = opts[:description]
end

Instance Attribute Details

#descriptionObject (readonly)

Returns the value of attribute description.



19
20
21
# File 'lib/littleneck_clamav/result.rb', line 19

def description
  @description
end

#pathObject (readonly)

Returns the value of attribute path.



9
10
11
# File 'lib/littleneck_clamav/result.rb', line 9

def path
  @path
end

Instance Method Details

#clean?Boolean

Returns:

  • (Boolean)


11
12
13
# File 'lib/littleneck_clamav/result.rb', line 11

def clean?
  @clean
end

#infected?Boolean

Returns:

  • (Boolean)


15
16
17
# File 'lib/littleneck_clamav/result.rb', line 15

def infected?
  !clean?
end