class Nexpose::UserAccount

User accounts on an asset.

Attributes

attributes[R]

Account attributes.

full_name[R]

Full name of the user.

id[R]

Unique identifier of the user as determined by the asset (not Nexpose).

name[R]

User account name.

Public Class Methods

new(name = nil, id = 0, full_name = nil, attributes = []) click to toggle source
# File lib/nexpose/asset.rb, line 153
def initialize(name = nil, id = 0, full_name = nil, attributes = [])
  @id, @name, @full_name, @attributes = id, name, full_name, attributes
end

Public Instance Methods

<=>(other) click to toggle source
# File lib/nexpose/asset.rb, line 164
def <=>(other)
  c = name <=> other.name
  return c unless c.zero?
  c = id <=> other.id
  return c unless c.zero?
  c = full_name <=> other.full_name
  return c unless c.zero?
  attributes <=> other.attributes
end
==(other) click to toggle source
# File lib/nexpose/asset.rb, line 174
def ==(other)
  eql?(other)
end
eql?(other) click to toggle source
# File lib/nexpose/asset.rb, line 178
def eql?(other)
  name.eql?(other.name) && id.eql?(other.id) && full_name.eql?(other.full_name) && attributes.eql?(other.attributes)
end
to_h() click to toggle source
# File lib/nexpose/asset.rb, line 157
def to_h
  { name: name,
    id: id,
    full_name: full_name,
    attributes: Attributes.to_hash(attributes) }
end