Skip to content
Snippets Groups Projects
Commit b1b584fa authored by Sam Yates's avatar Sam Yates Committed by Benjamin Cumming
Browse files

Implement mechanism ion rebinding. (#786)

* Make global parameters and ion rebindings part of the instantiate interface, rather than insist that all concrete mechanisms implement these as methods.
* Mechanism catalogue instance() returns a pair, comprising the concrete mechanism for the requested backend, together with the override data.
* Extend catalgoue derive() method to take a list of old ion name -> new ion name remappings for a mechanism.
* Add exceptions for ion remapping errors, and check for these errors.
* Add convenience function for reparameterizing a mechanism with a single ion dependency over other ions. (This will be used for the future nernst pre-supplied mechanism.)
* Add unit tests for: chained renamings of ion names across multiple derivations; correct shared state ion assignment after renamings; ion remapping exceptions; parameterize_over_ion.
parent 0aacf62d
No related branches found
No related tags found
Showing
with 461 additions and 145 deletions
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment