Trait feroxide::Reaction
[−]
[src]
pub trait Reaction<E: Element>: Properties { fn is_valid(&self) -> bool; fn equalise(&self) -> bool; fn energy_cost(&self) -> Energy; fn elem_reaction(&self) -> ElemReaction<E>; }
Required Methods
fn is_valid(&self) -> bool
Check if the reaction is valid by comparing the amount of total atoms on both sides, and by checking if the total charge on both sides is equal
fn equalise(&self) -> bool
Balance both sides of the equation to make sure it's valid Returns true if it managed to equalise it, false otherwise
fn energy_cost(&self) -> Energy
Calculate the cost of this reaction This can be negative in case of an exothermic reaction
fn elem_reaction(&self) -> ElemReaction<E>
Get the ElemReaction version
Implementors
impl<E: Element> Reaction<E> for ElemReaction<E>
impl<E: Element> Reaction<E> for RedoxReaction<E>