Philipp Hasenfratz: MIME::Entity

Beitrag lesen

Halihallo

hab mich bem Doku lesen grün und blau geärgert, als ich ...

---
Instance method. Get the encoded (transport-ready) body, as an array of lines. This is a read-only data structure: changing its contents will have no effect.                          ^-------------------^
          ^-------^
---

...las. Warum zum ... kann ich den Body eines Entities nicht nachträglich noch ändern? - Hab auch mal im Source des Moduls nachgeschaut und hab nur folgendes gefunden:

sub body {
    my ($self, $value) = @_;
    if (@_ > 1) {      ### setting body line(s)...
 croak "you cannot use body() to set the encoded contents\n";
        ^----------------------------------------------------------^
    }
    else {             ### getting body lines...
         ...
    }
}

zeimlich frech dieses Modul, wo ich doch nur den Text einer Mail kurz nachträglich ändern will, da ich dessen Inhalt beim build noch nicht kenne.

Jemand Kommentar oder gar Lösung???

Greets

Philipp