|
Java プラットフォームの監視と管理 | ||||||||
前のクラス 次のクラス | フレームあり フレームなし | ||||||||
概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド |
java.lang.Object com.sun.management.GcInfo
public class GcInfo
ガベージコレクション情報。この情報には、GC 固有の属性と 1 つのガベージコレクションに関する次の情報が含まれています。
- 開始時刻
- 終了時刻
- 期間
- コレクションが始まる前のメモリー使用状況
- コレクションが終了したあとのメモリー使用状況
GcInfo は、CompositeData
です。GC 固有の属性は、CompositeData インタフェースを使って取得できます。これは過去の名残りであり、ほかのクラスはこのパターンをコピーできません。代わりに CompositeDataView
を使用してください。
from
メソッドに指定された属性を持つ CompositeData
にマッピングされます。
メソッドの概要 | |
---|---|
boolean |
containsKey(String key)
Returns true if and only if this CompositeData instance contains an item whose name is key. |
boolean |
containsValue(Object value)
Returns true if and only if this CompositeData instance contains an item whose value is value. |
boolean |
equals(Object obj)
Indicates whether some other object is "equal to" this one. |
static GcInfo |
from(CompositeData cd)
指定された CompositeData により表された GcInfo オブジェクトを返します。 |
Object |
get(String key)
Returns the value of the item whose name is key. |
Object[] |
getAll(String[] keys)
Returns an array of the values of the items whose names are specified by keys, in the same order as keys. |
CompositeType |
getCompositeType()
Returns the composite type of this composite data instance. |
long |
getDuration()
この GC の経過時間をミリ秒単位で返します。 |
long |
getEndTime()
Java 仮想マシンが起動してからの GC の終了時刻をミリ秒単位で返します。 |
long |
getId()
このコレクタが実行したコレクション数のこのガベージコレクションの識別子を返します。 |
Map<String,MemoryUsage> |
getMemoryUsageAfterGc()
この GC が終了した時点の全メモリープールのメモリー使用状況を返します。 |
Map<String,MemoryUsage> |
getMemoryUsageBeforeGc()
この GC が開始された時点の全メモリープールのメモリー使用状況を返します。 |
long |
getStartTime()
Java 仮想マシンが起動してからの GC の開始時刻をミリ秒単位で返します。 |
int |
hashCode()
Returns a hash code value for the object. |
CompositeData |
toCompositeData(CompositeType ct)
GC 固有の属性を含む、この GcInfo の CompositeData 表現を返します。 |
String |
toString()
Returns a string representation of the object. |
Collection |
values()
Returns an unmodifiable Collection view of the item values contained in this CompositeData instance. |
クラス java.lang.Object から継承されたメソッド |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
メソッドの詳細 |
---|
public long getId()
public long getStartTime()
public long getEndTime()
public long getDuration()
public Map<String,MemoryUsage> getMemoryUsageBeforeGc()
public Map<String,MemoryUsage> getMemoryUsageAfterGc()
public static GcInfo from(CompositeData cd)
属性名 型 index java.lang.Long startTime java.lang.Long endTime java.lang.Long memoryUsageBeforeGc javax.management.openmbean.TabularData memoryUsageAfterGc javax.management.openmbean.TabularData
IllegalArgumentException
- cd が、上記の属性を持つ GcInfo オブジェクトを表さない場合public boolean containsKey(String key)
javax.management.openmbean.CompositeData
の記述:
CompositeData
内の containsKey
key
- the key to be tested.
public boolean containsValue(Object value)
javax.management.openmbean.CompositeData
の記述:
CompositeData
内の containsValue
value
- the value to be tested.
public boolean equals(Object obj)
java.lang.Object
の記述:
The equals
method implements an equivalence relation
on non-null object references:
x
, x.equals(x)
should return
true
.
x
and y
, x.equals(y)
should return true
if and only if
y.equals(x)
returns true
.
x
, y
, and z
, if
x.equals(y)
returns true
and
y.equals(z)
returns true
, then
x.equals(z)
should return true
.
x
and y
, multiple invocations of
x.equals(y) consistently return true
or consistently return false
, provided no
information used in equals
comparisons on the
objects is modified.
x
,
x.equals(null)
should return false
.
The equals method for class Object
implements
the most discriminating possible equivalence relation on objects;
that is, for any non-null reference values x
and
y
, this method returns true
if and only
if x
and y
refer to the same object
(x == y
has the value true
).
Note that it is generally necessary to override the hashCode method whenever this method is overridden, so as to maintain the general contract for the hashCode method, which states that equal objects must have equal hash codes.
CompositeData
内の equals
Object
内の equals
obj
- the reference object with which to compare.
true
if this object is the same as the obj
argument; false
otherwise.Object.hashCode()
,
Hashtable
public Object get(String key)
javax.management.openmbean.CompositeData
の記述:
CompositeData
内の get
key
- the name of the item.
public Object[] getAll(String[] keys)
javax.management.openmbean.CompositeData
の記述:
CompositeData
内の getAll
keys
- the names of the items.
public CompositeType getCompositeType()
javax.management.openmbean.CompositeData
の記述:
CompositeData
内の getCompositeType
public int hashCode()
java.lang.Object
の記述:java.util.Hashtable
.
The general contract of hashCode
is:
hashCode
method on each of
the two objects must produce the same integer result.
Object.equals(java.lang.Object)
method, then calling the hashCode method on each of the
two objects must produce distinct integer results. However, the
programmer should be aware that producing distinct integer results
for unequal objects may improve the performance of hashtables.
As much as is reasonably practical, the hashCode method defined by class Object does return distinct integers for distinct objects. (This is typically implemented by converting the internal address of the object into an integer, but this implementation technique is not required by the JavaTM programming language.)
CompositeData
内の hashCode
Object
内の hashCode
Object.equals(java.lang.Object)
,
Hashtable
public String toString()
java.lang.Object
の記述:toString
method returns a string that
"textually represents" this object. The result should
be a concise but informative representation that is easy for a
person to read.
It is recommended that all subclasses override this method.
The toString
method for class Object
returns a string consisting of the name of the class of which the
object is an instance, the at-sign character `@
', and
the unsigned hexadecimal representation of the hash code of the
object. In other words, this method returns a string equal to the
value of:
getClass().getName() + '@' + Integer.toHexString(hashCode())
CompositeData
内の toString
Object
内の toString
public Collection values()
javax.management.openmbean.CompositeData
の記述:
CompositeData
内の values
public CompositeData toCompositeData(CompositeType ct)
GC 固有の属性を含む、この GcInfo
の CompositeData
表現を返します。戻り値には、少なくとも from
メソッドに記述されたすべての属性と、任意でその他の属性が含まれます。
CompositeDataView
内の toCompositeData
ct
- 呼び出し側が予想する CompositeType
。このパラメータは無視される。null にすることができる
CompositeData
表現
|
Java プラットフォームの監視と管理 | ||||||||
前のクラス 次のクラス | フレームあり フレームなし | ||||||||
概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド |