Changes between Version 8 and Version 9 of EcosimVariableTimestepPluginExample


Ignore:
Timestamp:
2010-02-25 14:24:10 (14 years ago)
Author:
joeb
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • EcosimVariableTimestepPluginExample

    v8 v9  
    1919 
    2020==== Sub time step plugin points ==== 
    21 IEcosimSubTimestepsPlugin.!EcosimSubTimeStepBegin(!ByRef !BiomassAtTimestep() As Single, !ByVal !TimeInYears As Single, !ByVal DeltaT As Single, !ByVal !SubTimestepIndex As Integer, !ByVal !EcosimDatastructures As Object) 
     21{{{ 
     22IEcosimSubTimestepsPlugin.EcosimSubTimeStepBegin(ByRef BiomassAtTimestep() As Single, ByVal TimeInYears As Single, ByVal DeltaT As Single, ByVal SubTimestepIndex As Integer, ByVal EcosimDatastructures As Object) 
     23}}} 
     24 
    2225 
    2326 * Called at the start of a sub time step. 
    2427 * !BiomassAtTimestep() contains the biomass that will be used for the time step. Any changes to biomass by a plugin point will be use be by Ecosim for the time step. 
    2528 
    26 IEcosimSubTimestepsPlugin.!EcosimSubTimeStepEnd(!ByRef !BiomassAtTimestep() As Single, !ByVal !TimeInYears As Single, !ByVal DeltaT As Single, !ByVal !SubTimestepIndex As Integer, !ByVal !EcosimDatastructures As Object) 
     29{{{ 
     30IEcosimSubTimestepsPlugin.EcosimSubTimeStepEnd(ByRef BiomassAtTimestep() As Single, ByVal TimeInYears As Single, ByVal DeltaT As Single, ByVal SubTimestepIndex As Integer, ByVal EcosimDatastructures As Object) 
     31}}} 
     32 
    2733 
    2834 * Called at the end of a sub time step. 
     
    3036 
    3137= Running Ecosim on a separate thread = 
    32 Ecosim can be run on a separate thread from the user interface by setting the cEcosimDataStuctures.bMultiThreaded Boolean flag to True. The next time Ecosim is run it will run on its own thread. Once the Ecosim run has completed the cEcosimDataStuctures.bMultiThreaded flag will be automatically set to its default value of False and all subsequent run will be on the main application thread. All plug-in calls that originate on a thread other than the main thread will be marshaled to the main thread. This is for robustness, in .NET user interface controls cannot be accessed from a thread other than that which they were created on. Plug-ins are created and run on the main thread by the EwE framework. By automatically marshaling all plug-in calls to the main thread plug-in points do not have to marshal calls to an interface. 
     38Ecosim can be run on its own thread by setting the cEcosimDataStuctures.bMultiThreaded Boolean flag to True. The next time Ecosim is run it will run on its own thread. Once the Ecosim run has completed the cEcosimDataStuctures.bMultiThreaded flag will be automatically set to its default value of False and all subsequent runs will be on the main application thread. All plug-in calls that originate on a thread other than the main thread will be marshaled to the main thread. This is for robustness, in .NET user interface controls cannot be accessed from a thread other than that which they were created on. Plug-ins are created and run on the main thread by the EwE framework. By automatically marshaling all plug-in calls to the main thread plug-in points do not have to marshal calls to an interface.