cl::utfsm::samplingSystemUI::PlotPrinter Class Reference

Inheritance diagram for cl::utfsm::samplingSystemUI::PlotPrinter:
Inheritance graph
[legend]
Collaboration diagram for cl::utfsm::samplingSystemUI::PlotPrinter:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 PlotPrinter (SamplingSystemGUI ssg)
 PlotPrinter (SamplingSystemGUI ssg, PlotWidget widget, int position)
ArrayList< DataItemgetSamples ()
String getFilename ()
void startSample () throws CouldntAccessComponentEx, TypeNotSupportedEx,CouldntAccessPropertyEx, SamplingManagerException
void postProcessing ()
void setComponent (String component)
void setProperty (String property)
void setComponentAvailable (boolean available, String reason)
void setTimeWindow (float freq, int time)
void setDumpToFile (boolean value)

Protected Member Functions

void updateValue (DataItem item)

Private Member Functions

boolean openFile ()

Private Attributes

long samplesCounter
String filename = ""
FileWriter file
BufferedWriter writer
IsoDateFormat formater
boolean stopped
int position = 0
boolean dumpToFile = true

Constructor & Destructor Documentation

cl::utfsm::samplingSystemUI::PlotPrinter::PlotPrinter ( SamplingSystemGUI  ssg  )  [inline]

Constructor, initialize the sampling counter and creates a BeanMemoryWidget for representation.

Parameters:
ssg Sampling System Gui reference.

References formater, position, samplesCounter, stopped, and cl::utfsm::samplingSystemUI::DataPrinter::widget.

cl::utfsm::samplingSystemUI::PlotPrinter::PlotPrinter ( SamplingSystemGUI  ssg,
PlotWidget  widget,
int  position 
) [inline]

Constructor, initialize the sampling counter and sets the Widget as the one passed by reference.
Very useful when you need to draw in one widget, many Printers.

Parameters:
ssg Sampling System Gui reference.
widget The Widget in that this Printer will output graphically.

References formater, cl::utfsm::samplingSystemUI::PlotWidget::initializeNewPosition(), samplesCounter, and stopped.


Member Function Documentation

String cl::utfsm::samplingSystemUI::PlotPrinter::getFilename (  )  [inline]

Return the name of the file where the data is being dumped to, or the last file used.

Returns:

References filename.

ArrayList<DataItem> cl::utfsm::samplingSystemUI::PlotPrinter::getSamples (  )  [inline, virtual]

Since the samples are not stored in memory, nothing can be returned.

Implements cl::utfsm::samplingSystemUI::DataPrinter.

boolean cl::utfsm::samplingSystemUI::PlotPrinter::openFile (  )  [inline, private]
void cl::utfsm::samplingSystemUI::PlotPrinter::postProcessing (  )  [inline, virtual]

This method should be called after stopping the sampling.

Implements cl::utfsm::samplingSystemUI::DataPrinter.

References dumpToFile, samplesCounter, stopped, and writer.

void cl::utfsm::samplingSystemUI::PlotPrinter::setComponent ( String  component  )  [inline]
void cl::utfsm::samplingSystemUI::PlotPrinter::setComponentAvailable ( boolean  available,
String  reason 
) [inline]

Allows to handle whether a component is or isn't available to be sampled.

Parameters:
available True if the component is currently available.
reason A explanation of the cause why the component isn't available.

Reimplemented from cl::utfsm::samplingSystemUI::DataPrinter.

References position, cl::utfsm::samplingSystemUI::IGraphicalUpdater::setComponentAvailable(), and cl::utfsm::samplingSystemUI::DataPrinter::widget.

void cl::utfsm::samplingSystemUI::PlotPrinter::setDumpToFile ( boolean  value  )  [inline]
void cl::utfsm::samplingSystemUI::PlotPrinter::setProperty ( String  property  )  [inline]
void cl::utfsm::samplingSystemUI::PlotPrinter::setTimeWindow ( float  freq,
int  time 
) [inline]
void cl::utfsm::samplingSystemUI::PlotPrinter::startSample (  )  throws CouldntAccessComponentEx, TypeNotSupportedEx,CouldntAccessPropertyEx, SamplingManagerException [inline]

Starts the sampling, connecting to ACS Manager and the Sampling Manager.

Exceptions:
CouldntAccessComponentEx Component wasn't available at the time.
TypeNotSupportedEx Sampling Manager specific exception. Some types are currently not supported in acssamp.

Reimplemented from cl::utfsm::samplingSystemUI::DataPrinter.

References cl::utfsm::samplingSystemUI::IGraphicalUpdater::resetSampleCount(), stopped, and cl::utfsm::samplingSystemUI::DataPrinter::widget.

void cl::utfsm::samplingSystemUI::PlotPrinter::updateValue ( DataItem  item  )  [inline, protected, virtual]

Member Data Documentation

Referenced by openFile().

Referenced by getFilename(), and openFile().

Referenced by PlotPrinter(), and updateValue().


The documentation for this class was generated from the following file:

Generated by  doxygen 1.6.2