Class: Nexpose::AssetGroupSummary

Inherits:
Object
  • Object
show all
Defined in:
lib/nexpose/group.rb

Overview

Summary value object for asset group information.

Direct Known Subclasses

AssetGroup

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(id, name, desc, risk, dynamic) ⇒ AssetGroupSummary

Returns a new instance of AssetGroupSummary.



48
49
50
51
52
53
54
# File 'lib/nexpose/group.rb', line 48

def initialize(id, name, desc, risk, dynamic)
  @id          = id
  @name        = name
  @description = desc
  @risk_score  = risk
  @dynamic     = dynamic
end

Instance Attribute Details

#descriptionObject (readonly)

Returns the value of attribute description.



46
47
48
# File 'lib/nexpose/group.rb', line 46

def description
  @description
end

#dynamicObject (readonly)

Returns the value of attribute dynamic.



46
47
48
# File 'lib/nexpose/group.rb', line 46

def dynamic
  @dynamic
end

#idObject (readonly)

Returns the value of attribute id.



46
47
48
# File 'lib/nexpose/group.rb', line 46

def id
  @id
end

#nameObject (readonly)

Returns the value of attribute name.



46
47
48
# File 'lib/nexpose/group.rb', line 46

def name
  @name
end

#risk_scoreObject (readonly)

Returns the value of attribute risk_score.



46
47
48
# File 'lib/nexpose/group.rb', line 46

def risk_score
  @risk_score
end

Instance Method Details

#delete(connection) ⇒ Object

Delete this asset group and all associated data.

Parameters:

  • connection (Connection)

    Connection to security console.



64
65
66
# File 'lib/nexpose/group.rb', line 64

def delete(connection)
  connection.delete_asset_group(@id)
end

#dynamic?Boolean

Returns:

  • (Boolean)


56
57
58
# File 'lib/nexpose/group.rb', line 56

def dynamic?
  dynamic
end