Evolife
Evolife has been developed to study Genetic algorithms, Natural evolution and behavioural ecology.
Public Member Functions | Public Attributes | List of all members
Evolife.Graphics.Evolife_Window.Simulation_Control Class Reference

Interface with the simulation thread #. More...

Inheritance diagram for Evolife.Graphics.Evolife_Window.Simulation_Control:
Inheritance graph
[legend]

Public Member Functions

def __init__ (self, SimulationStep, Obs, method='timer')
 Stores Obs as observer and SimulationStep as the function that processes one step of the simulation. More...
 
def RunButtonClick (self, event=None)
 Entering in 'Run' mode. More...
 
def StepButtonClick (self, event=None)
 Entering in 'Step' mode. More...
 
def Simulation_stop (self)
 Stops the simulation thread or timer. More...
 
def Simulation_launch (self, continuous_mode)
 (re)starts the simulation thread or timer More...
 
def Simulation_resume (self)
 calls Simulation_launch More...
 
def OneStep (self)
 calls SimulationStep More...
 
def ReturnFromThread (self)
 to be overloaded More...
 
def DecisionToEnd (self)
 to be overloaded More...
 

Public Attributes

 Obs
 
 SimulationStep
 
 method
 
 timer
 
 simulation
 Status of the simulation programme. More...
 
 simulation_steady_mode
 
 simulation_under_way
 
 previous_Disp_period
 
 Disp_period
 

Detailed Description

Interface with the simulation thread #.

Controls the simulation, either step by step, or in a continuous mode.

Definition at line 44 of file Evolife_Window.py.

Constructor & Destructor Documentation

◆ __init__()

def Evolife.Graphics.Evolife_Window.Simulation_Control.__init__ (   self,
  SimulationStep,
  Obs,
  method = 'timer' 
)

Stores Obs as observer and SimulationStep as the function that processes one step of the simulation.

'method' can be 'timer' or 'thread' ('timer' preferred)

Reimplemented in Evolife.Graphics.Evolife_Window.Simulation_Control_Frame, Evolife.Graphics.Evolife_Window.Simulation_Display_Control_Frame, Evolife.Graphics.Evolife_Window.Simulation_Frame, and Evolife.Graphics.Evolife_Window.Evolife_Frame.

Definition at line 49 of file Evolife_Window.py.

Member Function Documentation

◆ DecisionToEnd()

def Evolife.Graphics.Evolife_Window.Simulation_Control.DecisionToEnd (   self)

to be overloaded

Reimplemented in Evolife.Graphics.Evolife_Window.Evolife_Frame.

Definition at line 145 of file Evolife_Window.py.

◆ OneStep()

def Evolife.Graphics.Evolife_Window.Simulation_Control.OneStep (   self)

calls SimulationStep

Definition at line 121 of file Evolife_Window.py.

◆ ReturnFromThread()

def Evolife.Graphics.Evolife_Window.Simulation_Control.ReturnFromThread (   self)

to be overloaded

Definition at line 140 of file Evolife_Window.py.

◆ RunButtonClick()

def Evolife.Graphics.Evolife_Window.Simulation_Control.RunButtonClick (   self,
  event = None 
)

Entering in 'Run' mode.

Definition at line 65 of file Evolife_Window.py.

◆ Simulation_launch()

def Evolife.Graphics.Evolife_Window.Simulation_Control.Simulation_launch (   self,
  continuous_mode 
)

(re)starts the simulation thread or timer

Definition at line 98 of file Evolife_Window.py.

◆ Simulation_resume()

def Evolife.Graphics.Evolife_Window.Simulation_Control.Simulation_resume (   self)

calls Simulation_launch

Definition at line 116 of file Evolife_Window.py.

◆ Simulation_stop()

def Evolife.Graphics.Evolife_Window.Simulation_Control.Simulation_stop (   self)

Stops the simulation thread or timer.

Definition at line 82 of file Evolife_Window.py.

◆ StepButtonClick()

def Evolife.Graphics.Evolife_Window.Simulation_Control.StepButtonClick (   self,
  event = None 
)

Entering in 'Step' mode.

Definition at line 73 of file Evolife_Window.py.

Member Data Documentation

◆ Disp_period

Evolife.Graphics.Evolife_Window.Simulation_Control.Disp_period

Definition at line 63 of file Evolife_Window.py.

◆ method

Evolife.Graphics.Evolife_Window.Simulation_Control.method

Definition at line 56 of file Evolife_Window.py.

◆ Obs

Evolife.Graphics.Evolife_Window.Simulation_Control.Obs

Definition at line 54 of file Evolife_Window.py.

◆ previous_Disp_period

Evolife.Graphics.Evolife_Window.Simulation_Control.previous_Disp_period

Definition at line 63 of file Evolife_Window.py.

◆ simulation

Evolife.Graphics.Evolife_Window.Simulation_Control.simulation

Status of the simulation programme.

Definition at line 60 of file Evolife_Window.py.

◆ simulation_steady_mode

Evolife.Graphics.Evolife_Window.Simulation_Control.simulation_steady_mode

Definition at line 61 of file Evolife_Window.py.

◆ simulation_under_way

Evolife.Graphics.Evolife_Window.Simulation_Control.simulation_under_way

Definition at line 62 of file Evolife_Window.py.

◆ SimulationStep

Evolife.Graphics.Evolife_Window.Simulation_Control.SimulationStep

Definition at line 55 of file Evolife_Window.py.

◆ timer

Evolife.Graphics.Evolife_Window.Simulation_Control.timer

Definition at line 57 of file Evolife_Window.py.


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