NAME
Math::Formula::Config - load/save formulas to file
INHERITANCE
Math::Formula::Config is extended by
Math::Formula::Config::INI
Math::Formula::Config::JSON
Math::Formula::Config::YAML
SYNOPSIS
my $saver = Math::Formula::Config::YAML->new(directory => $dir);
$saver->save($context);
DESCRIPTION
The extensions of this module can be used to export and import sets of expressions to and from a program.
The following serialization formats are supported:
JSON via Math::Formula::Config::JSON
YAML via Math::Formula::Config::YAML
INI via Math::Formula::Config::INI
METHODS
Constructors
Attributes
- $obj->directory()
-
When the configuration files will be written, and are read.
- $obj->path_for($file)
-
Constructs a filename, based on the configured directory(), the context's name, and the usual filename extensions.
Actions
- $obj->load($name, %options)
-
Load a Math::Formula::Context for an INI file.
-Option --Default filename <directory/$name.ini>
- $obj->save($context, %options)
-
Serialize the
$context
into a file as storage or to be edited by hand. This is a useful method when default configuration templates need to be generated.
DIAGNOSTICS
SEE ALSO
This module is part of Math-Formula version 0.18, built on August 19, 2025. Website: http://perl.overmeer.net/CPAN/
LICENSE
For contributors see file ChangeLog.
This software is copyright (c) 2023-2025 by Mark Overmeer.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.