Writeable, ToXContent, ToXContentFragmentpublic class OsStats extends java.lang.Object implements Writeable, ToXContentFragment
| Modifier and Type | Class | Description |
|---|---|---|
static class |
OsStats.Cgroup |
Encapsulates basic cgroup statistics.
|
static class |
OsStats.Cpu |
|
static class |
OsStats.Mem |
|
static class |
OsStats.Swap |
ToXContent.DelegatingMapParams, ToXContent.MapParams, ToXContent.ParamsWriteable.Reader<V>, Writeable.Writer<V>EMPTY_PARAMS| Constructor | Description |
|---|---|
OsStats(long timestamp,
OsStats.Cpu cpu,
OsStats.Mem mem,
OsStats.Swap swap,
OsStats.Cgroup cgroup) |
|
OsStats(StreamInput in) |
| Modifier and Type | Method | Description |
|---|---|---|
static short |
calculatePercentage(long used,
long max) |
|
OsStats.Cgroup |
getCgroup() |
|
OsStats.Cpu |
getCpu() |
|
OsStats.Mem |
getMem() |
|
OsStats.Swap |
getSwap() |
|
long |
getTimestamp() |
|
XContentBuilder |
toXContent(XContentBuilder builder,
ToXContent.Params params) |
|
void |
writeTo(StreamOutput out) |
Write this into the StreamOutput.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitisFragmentpublic OsStats(long timestamp,
OsStats.Cpu cpu,
OsStats.Mem mem,
OsStats.Swap swap,
OsStats.Cgroup cgroup)
public OsStats(StreamInput in) throws java.io.IOException
java.io.IOExceptionpublic void writeTo(StreamOutput out) throws java.io.IOException
Writeablepublic long getTimestamp()
public OsStats.Cpu getCpu()
public OsStats.Mem getMem()
public OsStats.Swap getSwap()
public OsStats.Cgroup getCgroup()
public XContentBuilder toXContent(XContentBuilder builder, ToXContent.Params params) throws java.io.IOException
toXContent in interface ToXContentjava.io.IOExceptionpublic static short calculatePercentage(long used,
long max)