Class MetricUpdater
- java.lang.Object
 - 
- bytemusketeers.heslingtonhustle.metrics.MetricUpdater
 
 
- 
public class MetricUpdater extends java.lang.ObjectTheMetricUpdaterprovides a common controller to link a singleMetricControllerandMetricListener, by means of enabling the former to post updates to the latter- Author:
 - ENG1 Team 23 (Cohort 3)
 
 
- 
- 
Field Summary
Fields Modifier and Type Field Description private MetricListenermetricListenerThe recipient of theMetricControllerupdates 
- 
Constructor Summary
Constructors Constructor Description MetricUpdater(MetricListener metricListener)Instantiates a newMetricUpdaterto provide updates to aMetricListeneron the transient states of aMetricController 
- 
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidsendUpdate(MetricController.Metric metric, java.lang.String value)Sends an update of a singleMetricController.Metricto the registeredMetricListener 
 - 
 
- 
- 
Field Detail
- 
metricListener
private final MetricListener metricListener
The recipient of theMetricControllerupdates 
 - 
 
- 
Constructor Detail
- 
MetricUpdater
public MetricUpdater(MetricListener metricListener)
Instantiates a newMetricUpdaterto provide updates to aMetricListeneron the transient states of aMetricController- Parameters:
 metricListener- The data-recipientMetricListener
 
 - 
 
- 
Method Detail
- 
sendUpdate
public void sendUpdate(MetricController.Metric metric, java.lang.String value)
Sends an update of a singleMetricController.Metricto the registeredMetricListener- See Also:
 metricListener
 
 - 
 
 -