parts[] = new ezcMailRfc822Digest( $part ); } else if ( $part instanceof ezcMailRfc822Digest ) { $this->parts[] = $part; } else if ( is_array( $part ) ) // add each and everyone of the parts in the array { foreach ( $part as $array_part ) { if ( $array_part instanceof ezcMail ) { $this->parts[] = new ezcMailRfc822Digest( $array_part ); } else if ( $array_part instanceof ezcMailRfc822Digest ) { $this->parts[] = $array_part; } } } } } /** * Appends a part to the list of parts. * * @param ezcMailRfc822Digest $part */ public function appendPart( ezcMailRfc822Digest $part ) { $this->parts[] = $part; } /** * Returns the mail parts associated with this multipart. * * @return array(ezcMail) */ public function getParts() { return $this->parts; } /** * Returns "digest". * * @return string */ public function multipartType() { return "digest"; } } ?>