Class: OsCtl::Lib::Zfs::IOStat::PoolStats

Inherits:
Struct
  • Object
show all
Defined in:
lib/libosctl/zfs/iostat.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#allocObject

Returns the value of attribute alloc

Returns:

  • (Object)

    the current value of alloc



3
4
5
# File 'lib/libosctl/zfs/iostat.rb', line 3

def alloc
  @alloc
end

#bytes_readObject

Returns the value of attribute bytes_read

Returns:

  • (Object)

    the current value of bytes_read



3
4
5
# File 'lib/libosctl/zfs/iostat.rb', line 3

def bytes_read
  @bytes_read
end

#bytes_writtenObject

Returns the value of attribute bytes_written

Returns:

  • (Object)

    the current value of bytes_written



3
4
5
# File 'lib/libosctl/zfs/iostat.rb', line 3

def bytes_written
  @bytes_written
end

#freeObject

Returns the value of attribute free

Returns:

  • (Object)

    the current value of free



3
4
5
# File 'lib/libosctl/zfs/iostat.rb', line 3

def free
  @free
end

#io_readObject

Returns the value of attribute io_read

Returns:

  • (Object)

    the current value of io_read



3
4
5
# File 'lib/libosctl/zfs/iostat.rb', line 3

def io_read
  @io_read
end

#io_writtenObject

Returns the value of attribute io_written

Returns:

  • (Object)

    the current value of io_written



3
4
5
# File 'lib/libosctl/zfs/iostat.rb', line 3

def io_written
  @io_written
end

#poolObject

Returns the value of attribute pool

Returns:

  • (Object)

    the current value of pool



3
4
5
# File 'lib/libosctl/zfs/iostat.rb', line 3

def pool
  @pool
end

Instance Method Details

#<<(other) ⇒ Object



12
13
14
15
16
17
18
19
# File 'lib/libosctl/zfs/iostat.rb', line 12

def <<(other)
  self.alloc = nil
  self.free = nil
  self.io_read += other.io_read
  self.io_written += other.io_written
  self.bytes_read += other.bytes_read
  self.bytes_written += other.bytes_written
end