package
module
Version:
v0.0.0-...-b7fb5d8
Opens a new window with list of versions in this module.
Published: Apr 18, 2021
License: MIT
Opens a new window with license information.
Imports: 4
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
README
¶
Documentation
¶
qalc provides a wrapper for the `qalc` executable
from Qalculate. `qalc` is an advanced calculator capable
of things such as solving equations.
func TypeFunc(answers []interface{}, tf TypeFuncs)
TypeFunc is a convenience function that loops through each parsed output
and runs the appropriate functions stored in an instance of TypeFuncs
type Qalc struct {
Commands []string
}
Qalc stores commands that will be provided to the `qalc` executable
New creates a new Qalc struct with the provided commands
AddCommands adds commands to a Qalc instance
func (q *Qalc) Execute() ([]interface{}, error)
Execute runs the `qalc` executable reading from Stdin,
setting Stdin to commands separrated by newline
TypeFuncs stores functions to be run if a certain type is found
Source Files
¶
Click to show internal directories.
Click to hide internal directories.