Top Description Fields Constructors Methods
sun.jvmstat.perfdata.monitor.protocol.file

public Class MonitoredHostProvider

extends MonitoredHost
Class Inheritance
Imports
sun.jvmstat.monitor.*, sun.jvmstat.monitor.event.HostListener, sun.jvmstat.perfdata.monitor.*, java.util.*, java.net.*

Concrete implementation of the MonitoredHost interface for the file: protocol of the HotSpot PerfData monitoring implementation.
Author
Brian Doherty
Since
1.5

Field Summary

Modifier and TypeField and Description
public static final int
DEFAULT_POLLING_INTERVAL

The default polling interval.

Inherited from sun.jvmstat.monitor.MonitoredHost:
hostIdintervallastException

Constructor Summary

AccessConstructor and Description
public
MonitoredHostProvider(HostIdentifier
the host identifier for this MonitoredHost
hostId
)

Create a MonitoredHostProvider instance using the given HostIdentifier.

Method Summary

Modifier and TypeMethod and Description
public Set<Integer>
activeVms()

Implements abstract sun.jvmstat.monitor.MonitoredHost.activeVms.

Return the current set of active Java Virtual Machines for this MonitoredHost.

public void
addHostListener(HostListener
the HostListener to add.
listener
)

Implements abstract sun.jvmstat.monitor.MonitoredHost.addHostListener.

Add a HostListener.

public void
detach(MonitoredVm
the monitored Java Virtual Machine.
vm
)

Implements abstract sun.jvmstat.monitor.MonitoredHost.detach.

Detach from the indicated MonitoredVm.

public MonitoredVm
getMonitoredVm(VmIdentifier
the VmIdentifier specifying the target Java Virtual Machine.
vmid
)

Implements abstract sun.jvmstat.monitor.MonitoredHost.getMonitoredVm.

Get the MonitoredVm for the given Java Virtual Machine.

public MonitoredVm
getMonitoredVm(VmIdentifier
the VmIdentifier specifying the target Java Virtual Machine.
vmid
,
int
the sampling interval for the target Java Virtual Machine.
interval
)

Implements abstract sun.jvmstat.monitor.MonitoredHost.getMonitoredVm.

Get the MonitoredVm for the given Java Virtual Machine.

public void
removeHostListener(HostListener
the HostListener to add.
listener
)

Implements abstract sun.jvmstat.monitor.MonitoredHost.removeHostListener.

Remove a HostListener.

Inherited from sun.jvmstat.monitor.MonitoredHost:
clearLastExceptiongetHostIdentifiergetIntervalgetLastExceptiongetMonitoredHostgetMonitoredHostgetMonitoredHostisErroredresolveHostIdsetIntervalsetLastException

Field Detail

DEFAULT_POLLING_INTERVALback to summary
public static final int DEFAULT_POLLING_INTERVAL

The default polling interval. Not used by the file: protocol.

Constructor Detail

MonitoredHostProviderback to summary
public MonitoredHostProvider(HostIdentifier hostId)

Create a MonitoredHostProvider instance using the given HostIdentifier.

Parameters
hostId:HostIdentifier

the host identifier for this MonitoredHost

Method Detail

activeVmsback to summary
public Set<Integer> activeVms()

Implements abstract sun.jvmstat.monitor.MonitoredHost.activeVms.

Doc from sun.jvmstat.monitor.MonitoredHost.activeVms.

Return the current set of active Java Virtual Machines for this MonitoredHost. The returned Set contains Integer instances holding the local virtual machine identifier, or lvmid for each instrumented Java Virtual Machine currently available..

Note - the file: protocol currently does not support the notion of tracking active or inactive Java Virtual Machines. This method currently returns an empty set.

Returns:Set<Integer>

Set - the current set of active Java Virtual Machines associated with this MonitoredHost, or the empty set of none.

addHostListenerback to summary
public void addHostListener(HostListener listener)

Implements abstract sun.jvmstat.monitor.MonitoredHost.addHostListener.

Doc from sun.jvmstat.monitor.MonitoredHost.addHostListener.

Add a HostListener. The given listener is added to the list of HostListener objects to be notified of MonitoredHost related events..

Note - the file: protocol currently does not support registration or notification of event listeners. This method silently ignores the add request.

Parameters
listener:HostListener

the HostListener to add.

detachback to summary
public void detach(MonitoredVm vm)

Implements abstract sun.jvmstat.monitor.MonitoredHost.detach.

Doc from sun.jvmstat.monitor.MonitoredHost.detach.

Detach from the indicated MonitoredVm.

Parameters
vm:MonitoredVm

the monitored Java Virtual Machine.

getMonitoredVmback to summary
public MonitoredVm getMonitoredVm(VmIdentifier vmid) throws MonitorException

Implements abstract sun.jvmstat.monitor.MonitoredHost.getMonitoredVm.

Doc from sun.jvmstat.monitor.MonitoredHost.getMonitoredVm.

Get the MonitoredVm for the given Java Virtual Machine. The default sampling interval is used for the MonitoredVm instance.

Parameters
vmid:VmIdentifier

the VmIdentifier specifying the target Java Virtual Machine.

Returns:MonitoredVm

MonitoredVm - the MonitoredVm instance for the target Java Virtual Machine.

Exceptions
MonitorException:
Thrown if monitoring errors occur.
getMonitoredVmback to summary
public MonitoredVm getMonitoredVm(VmIdentifier vmid, int interval) throws MonitorException

Implements abstract sun.jvmstat.monitor.MonitoredHost.getMonitoredVm.

Doc from sun.jvmstat.monitor.MonitoredHost.getMonitoredVm.

Get the MonitoredVm for the given Java Virtual Machine. The sampling interval is set to the given interval..

Note - the file: protocol silently ignores the interval parameter.

Parameters
vmid:VmIdentifier

the VmIdentifier specifying the target Java Virtual Machine.

interval:int

the sampling interval for the target Java Virtual Machine.

Returns:MonitoredVm

MonitoredVm - the MonitoredVm instance for the target Java Virtual Machine.

Exceptions
MonitorException:
Thrown if monitoring errors occur.
removeHostListenerback to summary
public void removeHostListener(HostListener listener)

Implements abstract sun.jvmstat.monitor.MonitoredHost.removeHostListener.

Doc from sun.jvmstat.monitor.MonitoredHost.removeHostListener.

Remove a HostListener. The given listener is removed from the list of HostListener objects to be notified of MonitoredHost related events..

Note - the file: protocol currently does not support registration or notification of event listeners. This method silently ignores the remove request.

Parameters
listener:HostListener

the HostListener to add.