public class DefaultOperatingSystems extends Object implements InternalOperatingSystems
DEFAULT_HISTORY_SIZE, DEFAULT_MONITOR_INTERVAL
Constructor and Description |
---|
DefaultOperatingSystems(InternalAdmin admin) |
Modifier and Type | Method and Description |
---|---|
void |
addOperatingSystem(OperatingSystem operatingSystem) |
Admin |
getAdmin()
Returns the
Admin associated with this element. |
OperatingSystem |
getByUID(String uid)
Returns the operating system matching its uid.
|
OperatingSystemsDetails |
getDetails()
Returns an aggregated view of all the operating systems details.
|
OperatingSystem[] |
getOperatingSystems()
Returns all currently discovered operating systems.
|
OperatingSystemStatisticsChangedEventManager |
getOperatingSystemStatisticsChanged()
Allows to register
OperatingSystemStatisticsChangedEventListener
to be notified when statistics have changed. |
int |
getSize()
Returns the number of operating systems current discovered.
|
OperatingSystemsStatistics |
getStatistics()
Returns an aggregated view of all the operating systems statistics.
|
OperatingSystemsStatisticsChangedEventManager |
getStatisticsChanged()
Allows to register
OperatingSystemsStatisticsChangedEventListener
to be notified when statistics have changed. |
Map<String,OperatingSystem> |
getUids()
Returns a map of operating systems with the key as the uid.
|
boolean |
isMonitoring()
Returns
true if statistics are now being monitored. |
Iterator<OperatingSystem> |
iterator() |
void |
removeOperatingSystem(String uid) |
void |
setStatisticsHistorySize(int historySize)
Sets the history size of number of statistics stored.
|
void |
setStatisticsInterval(long interval,
TimeUnit timeUnit)
Sets the statistics interval, automatically updating the monitoring scheduled tasks if
monitoring is enabled.
|
void |
startStatisticsMonitor()
Starts the statistics monitor, starting a scheduled monitor that polls for statistics.
|
void |
stopStatisticsMonitor()
Stops the statistics monitor.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
forEach, spliterator
public DefaultOperatingSystems(InternalAdmin admin)
public Admin getAdmin()
AdminAware
Admin
associated with this element.getAdmin
in interface AdminAware
public OperatingSystem[] getOperatingSystems()
OperatingSystems
getOperatingSystems
in interface OperatingSystems
public Iterator<OperatingSystem> iterator()
iterator
in interface Iterable<OperatingSystem>
public int getSize()
OperatingSystems
getSize
in interface OperatingSystems
public OperatingSystemsDetails getDetails()
OperatingSystems
getDetails
in interface OperatingSystems
public OperatingSystemsStatistics getStatistics()
OperatingSystems
getStatistics
in interface OperatingSystems
public void setStatisticsInterval(long interval, TimeUnit timeUnit)
StatisticsMonitor
setStatisticsInterval
in interface StatisticsMonitor
public void setStatisticsHistorySize(int historySize)
StatisticsMonitor
setStatisticsHistorySize
in interface StatisticsMonitor
public void startStatisticsMonitor()
StatisticsMonitor
startStatisticsMonitor
in interface StatisticsMonitor
public void stopStatisticsMonitor()
StatisticsMonitor
stopStatisticsMonitor
in interface StatisticsMonitor
public boolean isMonitoring()
StatisticsMonitor
true
if statistics are now being monitored.isMonitoring
in interface StatisticsMonitor
public OperatingSystemsStatisticsChangedEventManager getStatisticsChanged()
OperatingSystems
OperatingSystemsStatisticsChangedEventListener
to be notified when statistics have changed. Note, statistics monitoring need to be started
using StatisticsMonitor.startStatisticsMonitor()
in order to receive events.getStatisticsChanged
in interface OperatingSystems
public OperatingSystemStatisticsChangedEventManager getOperatingSystemStatisticsChanged()
OperatingSystems
OperatingSystemStatisticsChangedEventListener
to be notified when statistics have changed. Note, statistics monitoring need to be started
using StatisticsMonitor.startStatisticsMonitor()
in order to receive events.getOperatingSystemStatisticsChanged
in interface OperatingSystems
public OperatingSystem getByUID(String uid)
OperatingSystems
getByUID
in interface OperatingSystems
public Map<String,OperatingSystem> getUids()
OperatingSystems
getUids
in interface OperatingSystems
public void addOperatingSystem(OperatingSystem operatingSystem)
addOperatingSystem
in interface InternalOperatingSystems
public void removeOperatingSystem(String uid)
removeOperatingSystem
in interface InternalOperatingSystems
Copyright © GigaSpaces.