Not all target virtual machines support this operation. Use {@link VirtualMachine#canGetInstanceInfo()}to determine if the operation is supported.
@see ReferenceType#instances(long)
@see ObjectReference#referringObjects(long)
@param refTypes the list of {@link ReferenceType} objects for which countsare to be obtained.
@return an array of long
containing one element for eachelement in the 'refTypes' list. Element i of the array contains the number of instances in the target VM of the ReferenceType at position i in the 'refTypes' list. If the 'refTypes' list is empty, a zero-length array is returned. If a ReferenceType in refTypes has been garbage collected, zero is returned for its instance count.
@throws java.lang.UnsupportedOperationException ifthe target virtual machine does not support this operation - see {@link VirtualMachine#canGetInstanceInfo() canGetInstanceInfo()}
@throws NullPointerException if the 'refTypes' list is null.
@since 1.6
|
|