Class AbstractSimulationEngine

    • Constructor Detail

      • AbstractSimulationEngine

        protected AbstractSimulationEngine()
        Builds an instance of this abstract simulation engine, containing no probes.
    • Method Detail

      • addProbe

        public void addProbe​(String identifier,
                             IProbe probe)
        Adds a probe to this simulation engine.
        Specified by:
        addProbe in interface ISimulationEngine
        Parameters:
        identifier - An unique identifier for the probe.
        probe - The probe to add to this simulation engine.
      • removeProbe

        public IProbe removeProbe​(String identifier)
        Removes a probe from the simulation engine.
        Specified by:
        removeProbe in interface ISimulationEngine
        Parameters:
        identifier - The identifier of the probe to remove.
        Returns:
        The removed probe, null if no probe having the provided identifier was registered to this engine.
      • getProbesIdentifiers

        public Set<String> getProbesIdentifiers()
        Lists the identifier of all the probes that are registered to this engine.
        Specified by:
        getProbesIdentifiers in interface ISimulationEngine
        Returns:
        The identifier of all the probes that are registered to this engine.
      • getProbe

        public IProbe getProbe​(String probeId)
        Gets the probe having a specific id. The probe has to be registered to this engine using the ISimulationEngine.addProbe(String, IProbe) method.
        Parameters:
        probeId - The identifier of the probe that was provided when it was added.
        Returns:
        The probe having the specific id.
        Throws:
        NoSuchElementException - If no probe is defined for the specified id.
      • getProbes

        public Collection<IProbe> getProbes()
        Gets the probes that are registered to this simulation engine.
        Returns:
        The probes that are registered to this simulation engine.