StateLogger

public class StateLogger extends AbstractLogger

Records the fluorophore states to a file. The StateLogger is a singleton.

Author:Kyle M. Douglass

Methods

getElapsedTimes

public ArrayList<Double> getElapsedTimes()

getFilename

public String getFilename()

Return the current filename for the log file.

Returns:filename

getIds

public ArrayList<Integer> getIds()

getInitialStates

public ArrayList<Integer> getInitialStates()

getInstance

public static StateLogger getInstance()
Returns:An instance of the singleton.

getNextStates

public ArrayList<Integer> getNextStates()

logStateTransition

public void logStateTransition(int id, double timeElapsed, int initialState, int nextState)

Simple logger for state transitions and their times.

Parameters:
  • id – integer ID of the emitter
  • timeElapsed – The time spent in the current state
  • initialState – integer ID of the original state
  • nextState – integer ID for the new fluorophore state

reset

public void reset()

Resets the logger to its initial state.

saveLogFile

public void saveLogFile()

Saves the state of the logger to a file.

Throws:
  • IOException