org.mbari.siam.distributed.jddac
Class SummaryBlock

java.lang.Object
  extended by net.java.jddac.common.fblock.Entity
      extended by net.java.jddac.jmdi.fblock.FunctionBlock
          extended by org.mbari.jddac.RelayBlock
              extended by org.mbari.siam.distributed.jddac.InstrumentServiceBlock
                  extended by org.mbari.siam.distributed.jddac.SummaryBlock
All Implemented Interfaces:
java.io.Serializable, net.java.jddac.common.util.ConfigurationInterface, net.java.jddac.jmdi.service.SubscriberCallback

public class SummaryBlock
extends InstrumentServiceBlock

Created by IntelliJ IDEA. User: brian Date: Mar 29, 2006 Time: 1:04:07 PM To change this template use File | Settings | File Templates.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class org.mbari.siam.distributed.jddac.InstrumentServiceBlock
KEY_SENSORDATAPACKET, OpIdProcessDevicePacket
 
Fields inherited from class org.mbari.jddac.RelayBlock
OpIdAddFunction
 
Fields inherited from class net.java.jddac.jmdi.fblock.FunctionBlock
BL_ACTIVE, BL_INACTIVE, BL_UNINITIALIZED, blockMajorState, blockModelNumber, blockVersion, FB_IDLE, FB_RUNNING, FB_STOPPED, functionBlockState, groupIds, META_TEDS, OpIdClear, OpIdConfigure, OpIdGetAllMetaData, OpIdGetBlockMajorState, OpIdGetFunctionBlockState, OpIdGetGroupIDs, OpIdGetMetaData, OpIdPause, OpIdResume, OpIdStart, pubPortsProperty, subPortsProperty
 
Fields inherited from class net.java.jddac.common.fblock.Entity
description, instanceName, META_CLASS, META_NAME, META_OPERATIONS, objectProperties, OpIdGetAttribute, OpIdGetClassName, OpIdGetDescription, OpIdGetInstanceName, OpIdGetObjectProperties, OpIdGetOwningBlockObjectTag, OpIdSetAttribute, OpIdSetInstanceName, owningBlockObjectName, PerformInputArg, PerformResult
 
Constructor Summary
SummaryBlock()
           
 
Method Summary
 void addVariableName(java.lang.String variableName)
           
 void doSummary()
           
 int getSampleCount()
           
 StatsBlock getStatsBlock()
           
 net.java.jddac.common.type.ArgArray perform(java.lang.String server_operation_id, net.java.jddac.common.type.ArgArray server_input_arguments)
          Performs the operation using server_input_arguments as the argument to the function used for processing
 void processDevicePacket(DevicePacket packet)
           
 void removeVariableName(java.lang.String variableName)
           
 void setInstrumentService(BaseInstrumentService instrumentService)
           
 void setSampleCount(int count)
           
 
Methods inherited from class org.mbari.siam.distributed.jddac.InstrumentServiceBlock
getInstrumentService
 
Methods inherited from class org.mbari.jddac.RelayBlock
addChild, addFunction, getChildren, removeChild
 
Methods inherited from class net.java.jddac.jmdi.fblock.FunctionBlock
clear, configure, destroy, destroyDeferredThread, getBlockMajorState, getBlockModelNumber, getBlockVersion, getEntityMetaData, getFunctionBlockState, getGroupIDs, getPubIDFromName, getSubIDFromName, goActive, initialize, notifySubscriber, pause, publish, publishDeferred, reset, resume, setGroupIDs, start
 
Methods inherited from class net.java.jddac.common.fblock.Entity
addOpTableMeta, getDescription, getInstanceName, getObjectProperties, getObjectPropery, getOwningBlockObjectName, setDescription, setInstanceName, setObjectProperties, setObjectProperty, setOwningBlockObjectName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SummaryBlock

public SummaryBlock()
Method Detail

doSummary

public void doSummary()

perform

public net.java.jddac.common.type.ArgArray perform(java.lang.String server_operation_id,
                                                   net.java.jddac.common.type.ArgArray server_input_arguments)
                                            throws java.lang.Exception,
                                                   net.java.jddac.common.exception.OpException
Description copied from class: RelayBlock

Performs the operation using server_input_arguments as the argument to the function used for processing

You can set the function used by calling:

 relatyBlock.addFunction(FunctionFactory.createFunctionArg(OpIdIn, OpIdOut, new SomeIFunction());
 

Overrides:
perform in class RelayBlock
Throws:
java.lang.Exception
net.java.jddac.common.exception.OpException

getSampleCount

public int getSampleCount()
Returns:
The number of samples that can be stored in the summaryBlock

setSampleCount

public void setSampleCount(int count)
Parameters:
count - The maximum number of samples that the SummaryBlock will hold. If samples beyond this value are added then the oldest samples are removed from the summary block and the new sample is added.

addVariableName

public void addVariableName(java.lang.String variableName)

removeVariableName

public void removeVariableName(java.lang.String variableName)

processDevicePacket

public void processDevicePacket(DevicePacket packet)
                         throws java.lang.Exception
Specified by:
processDevicePacket in class InstrumentServiceBlock
Throws:
java.lang.Exception

setInstrumentService

public void setInstrumentService(BaseInstrumentService instrumentService)
Overrides:
setInstrumentService in class InstrumentServiceBlock

getStatsBlock

public StatsBlock getStatsBlock()


Copyright © 2003 MBARI.

The Monterey Bay Aquarium Research Institute (MBARI) provides this documentation and code "as is", with no warranty, express or implied, of its quality or consistency. It is provided without support and without obligation on the part of MBARI to assist in its use, correction, modification, or enhancement.