org.apache.ignite.internal.visor.igfs

## Class VisorIgfsMetrics

- java.lang.Object
- - org.apache.ignite.internal.visor.VisorDataTransferObject
  - - org.apache.ignite.internal.visor.igfs.VisorIgfsMetrics

All Implemented Interfaces:
  Externalizable, Serializable

    public class VisorIgfsMetrics
    extends VisorDataTransferObject

Data transfer object for `IgfsMetrics`.

See Also:
  Serialized Form

### Field Summary

### Fields inherited from class org.apache.ignite.internal.visor.VisorDataTransferObject

`V1, V2`

### Constructor Summary

Constructors
Constructor and Description
`VisorIgfsMetrics()` Create data transfer object for given IGFS metrics.
`VisorIgfsMetrics(IgniteFileSystem igfs)` Create data transfer object for given IGFS metrics.

### Method Summary

Methods
`VisorIgfsMetrics` `add(VisorIgfsMetrics m)` Add given metrics.
`VisorIgfsMetrics` `aggregate(int n)` Aggregate metrics.
`long` `getBlocksRead()`
`long` `getBlocksReadRemote()`
`long` `getBlocksWritten()`
`long` `getBlocksWrittenRemote()`
`long` `getBytesRead()`
`long` `getBytesReadTime()`
`long` `getBytesWriteTime()`
`long` `getBytesWritten()`
`int` `getFilesCount()`
`int` `getFilesOpenedForRead()`
`int` `getFilesOpenedForWrite()`
`int` `getFoldersCount()`
`long` `getFreeSpaceSize()`
`long` `getTotalSpaceSize()`
`long` `getUsedSpaceSize()`
`protected void` `readExternalData(byte protoVer, ObjectInput in)` Load object's specific data content.
`String` `toString()`
`protected void` `writeExternalData(ObjectOutput out)` Save object's specific data content.

### Methods inherited from class org.apache.ignite.internal.visor.VisorDataTransferObject

`getProtocolVersion, readExternal, toList, toSet, writeExternal`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

### Constructor Detail

#### VisorIgfsMetrics

    public VisorIgfsMetrics()

Create data transfer object for given IGFS metrics.

#### VisorIgfsMetrics

    public VisorIgfsMetrics(IgniteFileSystem igfs)

Create data transfer object for given IGFS metrics.

Parameters:
  `igfs` - Source IGFS.

### Method Detail

#### add

    public VisorIgfsMetrics add(VisorIgfsMetrics m)

Add given metrics.

Parameters:
  `m` - Metrics to add.
Returns:
  Self for method chaining.

#### aggregate

    public VisorIgfsMetrics aggregate(int n)

Aggregate metrics.

Parameters:
  `n` - Nodes count.
Returns:
  Self for method chaining.

#### getTotalSpaceSize

    public long getTotalSpaceSize()

Returns:
  Maximum amount of data that can be stored on local node.

#### getUsedSpaceSize

    public long getUsedSpaceSize()

Returns:
  Local used space in bytes on local node.

#### getFreeSpaceSize

    public long getFreeSpaceSize()

Returns:
  Local free space in bytes on local node.

#### getFoldersCount

    public int getFoldersCount()

Returns:
  Number of directories created in file system.

#### getFilesCount

    public int getFilesCount()

Returns:
  Number of files stored in file system.

#### getFilesOpenedForRead

    public int getFilesOpenedForRead()

Returns:
  Number of files that are currently opened for reading on local node.

#### getFilesOpenedForWrite

    public int getFilesOpenedForWrite()

Returns:
  Number of files that are currently opened for writing on local node.

#### getBlocksRead

    public long getBlocksRead()

Returns:
  Total blocks read, local and remote.

#### getBlocksReadRemote

    public long getBlocksReadRemote()

Returns:
  Total remote blocks read.

#### getBlocksWritten

    public long getBlocksWritten()

Returns:
  Total blocks write, local and remote.

#### getBlocksWrittenRemote

    public long getBlocksWrittenRemote()

Returns:
  Total remote blocks write.

#### getBytesRead

    public long getBytesRead()

Returns:
  Total bytes read.

#### getBytesReadTime

    public long getBytesReadTime()

Returns:
  Total bytes read time.

#### getBytesWritten

    public long getBytesWritten()

Returns:
  Total bytes write.

#### getBytesWriteTime

    public long getBytesWriteTime()

Returns:
  Total bytes write time.

#### writeExternalData

    protected void writeExternalData(ObjectOutput out)
                              throws IOException

Save object's specific data content.

Specified by:
  `writeExternalData` in class `VisorDataTransferObject`
Parameters:
  `out` - Output object to write data content.
Throws:
  `IOException` - If I/O errors occur.

#### readExternalData

    protected void readExternalData(byte protoVer,
                        ObjectInput in)
                             throws IOException,
                                    ClassNotFoundException

Load object's specific data content.

Specified by:
  `readExternalData` in class `VisorDataTransferObject`
Parameters:
  `protoVer` - Input object version.
  `in` - Input object to load data content.
Throws:
  `IOException` - If I/O errors occur.
  `ClassNotFoundException` - If the class for an object being restored cannot be found.

#### toString

    public String toString()

Overrides:
  `toString` in class `Object`

2017 Copyright © Apache Software Foundation

Follow @ApacheIgnite

Ignite Fabric | : ver. 2.1.0
Release Date | : July 20 2017