edu.cmu.cs.able.gaugeInfrastructure.RMI
Class RMIGaugeMgr

java.lang.Object
  |
  +--edu.cmu.cs.able.gaugeInfrastructure.RMI.RMIGaugeMgr
All Implemented Interfaces:
GaugeMgr, java.io.Serializable

public class RMIGaugeMgr
extends java.lang.Object
implements GaugeMgr, java.io.Serializable

See Also:
Serialized Form

Field Summary
protected static java.lang.String busHost
           
protected  RMIGaugeReportingBus gaugeBus
           
protected  java.lang.String gaugeMgrType
           
protected  java.lang.String gaugeMgrUID
           
 
Constructor Summary
RMIGaugeMgr(java.lang.String host)
          Constructor of RMIGaugeMgr
 
Method Summary
 GaugeControl createGauge(GaugeID gauge, StringPairVector setupParams, StringPairVector mappings)
          Creates a new gauge with the information specified.
 boolean deleteGauge(GaugeControl gauge)
          Deletes a gauge.
 java.lang.String getGaugeMgrID()
          Each gauge manager has a unique ID.
 java.lang.String getGaugeMgrType()
           
 boolean managesType(java.lang.String gaugeType)
          Determines whether this gauge manager can manage gauges of a particular type.
 boolean queryMetaInfo(java.lang.String gaugeType, StringPairVector configParamsMeta, StringPairVector valuesMeta)
          Fills in the type information for a gauge type.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

gaugeBus

protected RMIGaugeReportingBus gaugeBus

gaugeMgrUID

protected java.lang.String gaugeMgrUID

gaugeMgrType

protected java.lang.String gaugeMgrType

busHost

protected static java.lang.String busHost
Constructor Detail

RMIGaugeMgr

public RMIGaugeMgr(java.lang.String host)
Constructor of RMIGaugeMgr
Method Detail

getGaugeMgrID

public java.lang.String getGaugeMgrID()
Description copied from interface: GaugeMgr
Each gauge manager has a unique ID.
Specified by:
getGaugeMgrID in interface GaugeMgr
Following copied from interface: edu.cmu.cs.able.gaugeInfrastructure.GaugeMgr
Returns:
The identifier of the gauge manager.

getGaugeMgrType

public java.lang.String getGaugeMgrType()

createGauge

public GaugeControl createGauge(GaugeID gauge,
                                StringPairVector setupParams,
                                StringPairVector mappings)
Description copied from interface: GaugeMgr
Creates a new gauge with the information specified.
Specified by:
createGauge in interface GaugeMgr
Following copied from interface: edu.cmu.cs.able.gaugeInfrastructure.GaugeMgr
Parameters:
gauge - The ID of the gauge to be created.
setupParams - The parameters with which to set up the gauge.
mappings - The mappings of values to model properties for how the gauge should report values.
Returns:
A new GaugeControl interface. Note that the GaugeID of this GaugeControl may be different to the GaugeID passed in as paramters. In particular, the modelName and uid may be different.

managesType

public boolean managesType(java.lang.String gaugeType)
Description copied from interface: GaugeMgr
Determines whether this gauge manager can manage gauges of a particular type.
Specified by:
managesType in interface GaugeMgr
Following copied from interface: edu.cmu.cs.able.gaugeInfrastructure.GaugeMgr
Parameters:
gaugeType - The type of the gauge being queried
Returns:
true if the gauge manager managers this type; false otherwise.

deleteGauge

public boolean deleteGauge(GaugeControl gauge)
Description copied from interface: GaugeMgr
Deletes a gauge. A gauge will send out a final delete announcement so that all consumers can be informed.
Specified by:
deleteGauge in interface GaugeMgr
Following copied from interface: edu.cmu.cs.able.gaugeInfrastructure.GaugeMgr
Parameters:
gauge - The gauge to be deleted.
Returns:
true if the gauge was deleted; false otherwise.

queryMetaInfo

public boolean queryMetaInfo(java.lang.String gaugeType,
                             StringPairVector configParamsMeta,
                             StringPairVector valuesMeta)
Description copied from interface: GaugeMgr
Fills in the type information for a gauge type.
Specified by:
queryMetaInfo in interface GaugeMgr
Following copied from interface: edu.cmu.cs.able.gaugeInfrastructure.GaugeMgr
Parameters:
gaugeType - The type of the gauge for which information is being queried.
configParamsMeta - Filled in with the parameters that can be used to configure a gauge as (name, type) pairs.
valuesMeta - Filled in with the values that the gauge can report, as (name, type) pairs.
Returns:
true if the information could be determined; false otherwise.