App::SpamcupNG::Summary - class to summarise SPAM report data


    use App::SpamcupNG::Summary;
    my $summary = App::SpamcupNG::Summary->new;


This class is used internally to store SPAM report data that can latter be saved to generate reports.

This class is also based on Class::Accessor and uses follow_best_practice.


tracking_id: the SPAM report unique tracking ID.
mailer: the e-mail header X-Mailer, if available. Might be undef.
content_type: the e-mail header Content-Type, if available. Might be undef.
age: the time elapsed since the SPAM e-mail was received.
age_unit: the time elapsed unit since the SPAM e-mail was received.
contacts: an array reference with the "best contacts" found in the report.
receivers: an array reference with App::SpamcupNG::Summary::Receiver instances.

Sometimes the receivers addresses will not real ones, but "counters" that will not be used for the report, but only for Spamcop statistics.



Creates a new instance. No parameter is required or expected.


Returns the summary attributes as strings, separated by commas.

If some of attributes are undef, the string not avaialable will be used instead.


Returns the tracking URL of the SPAM report as a string.


Getter for attributes that returns the value as a string.

If the attribute value is undef, the string return by na() will be used instead.

Expects as parameter the name of the parameter, returns a string.


Returns the "not available" string. Can be used as class method.


Setter for the receivers attribute.

Expects as parameter an array reference, with inner array references inside.

Returns "true" (1) if everything goes fine.



Alceu Rodrigues de Freitas Junior, <>


This software is copyright (c) 2018 of Alceu Rodrigues de Freitas Junior, <>

This file is part of App-SpamcupNG distribution.

App-SpamcupNG is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

App-SpamcupNG is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with App-SpamcupNG. If not, see <>.