Oryx::Value::Complex - Values containing complex Perl types
package CMS::Setting; use base qw( Oryx::Class ); our $schema = { attributes => [ { name => 'setting_key', type => 'String', }, { name => 'setting_value', type => 'Complex', } ], }; $x = CMS::Setting->create({ setting_key => 'my_setting', setting_value => { foo => 1, bar => 2, baz => [ 1, 2, 3 ], }, });
This is a good catch-all type for many kinds of Perl data. It can store any arbitrarily complex data structure that is serializable with YAML. This includes almost anything. However, you should probably see that documentation and test your particular data first as YAML cannot serialize everything.
This value type does not perform any work to check, but uses YAML to inflate and deflate the data into the "Text" primitive type.
Oryx::Value, YAML
Richard Hundt <richard NO SPAM AT protea-systems.com>
Andrew Sterling Hanenkamp <hanenkamp@cpan.org>
This library is free software and may be used under the same terms as Perl itself.
To install Oryx, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Oryx
CPAN shell
perl -MCPAN -e shell install Oryx
For more information on module installation, please visit the detailed CPAN module installation guide.