View on
MetaCPAN is shutting down
For details read Perl NOC. After June 25th this page will redirect to
Dave Rolsky > Chloro > Chloro::ResultSet



Annotate this POD



Open  0
View/Report Bugs
Module Version: 0.07   Source  


Chloro::ResultSet - The set of results from processing a form submission


version 0.07


    my $resultset = $form->process( params => $params );

    if ( $resultset->is_valid() ) {
        do_something( $resultset->results_as_hash() ):
    else {
        # handle errors


This class represents the set of results from processing an entire form submission.

This includes results for individual fields and for groups, as well as validation errors for the form as a whole.


This class has the following methods:


The constructor accepts the following arguments:


Returns a list of Chloro::Result::Field and Chloro::Result::Group objects.


Given a field name or a group prefix, returns a Chloro::Result::Field or Chloro::Result::Group object


This returns true if there are no field or form errors in this resultset.


This takes all the result objects as assembles them into a data hash reference. See Chloro::Manual::Groups for details on how group results are returned.


This is just like $resultset->results_as_hash(), but the result for any field marked as secure is omitted. This is useful if you need to pass the form data in a query string or session, and you don't want to include things like credit card numbers or passwords.


Returns a hash reference of the original parameters passed to $form->process() with any fields marked secure removed.

Note that if the keys in the original params do not match the field names (because you used a custom extractor), then those keys will still be in the returned hash reference.


Returns a list of Chloro::Error::Form objects. This list may be empty.


Adds a Chloro::Error::Form object to the resultset.


This returns a hash of errors associated with the fields. The hash keys are either plain field names, or a prefixed name for fields in groups. The value for each key is an array reference of error objects.

Fields without errors are not included in the hash.


This method returns all the errors in the resultset, both form and field. They are returned a list.


This class does the Chloro::Role::Result and Chloro::Role::ResultSet role.


Bugs may be submitted at or via email to

I am also usually active on IRC as 'autarch' on irc://


The source code repository for Chloro can be found at


Dave Rolsky <>


This software is Copyright (c) 2017 by Dave Rolsky.

This is free software, licensed under:

  The Artistic License 2.0 (GPL Compatible)

The full text of the license can be found in the LICENSE file included with this distribution.

syntax highlighting: