MapiMessage
סקירה כללית
MapiMessage הוא שיעור ב Aspose.Email FOSS עבור Python.
• Mutable MSG Object ברמה גבוהה עם תמיכה ב-MSG ו- EmailMessage Conversion.
שיעור זה מספק 22 שיטות לעבוד עם אובייקטים MapiMessage בתוכניות Python. שיטות זמינות כוללות: add_attachment, add_embedded_message_attachment, add_recipient, close, create, from_email_message, from_file, from_msg_document, get_named_property, get_property, get_property_value, iter_attachments_info,10 שיטות נוספות. כל החברים הציבוריים זמינים לכל יישום Python לאחר התקנת Aspose.Email FOSS עבור חבילת Python. רכוש : attachments, body, body_html, declared_attachment_count, declared_next_attachment_id, declared_next_recipient_id,19 ועוד.
נכסים
| שם | סוג | גישה | תיאור |
|---|---|---|---|
msg_reader | MsgReader | קראו | קבל את הקורא של MSG. |
validation_issues | tuple[str, ...] | קראו | יש בעיות של אימות. |
subject | `str | None` | קרא / כתיבה |
body | `str | None` | קרא / כתיבה |
message_class | `str | None` | קרא / כתיבה |
body_html | `str | None` | קרא / כתיבה |
unicode_strings | bool | קרא / כתיבה | מקבל או מונח את הקווים של Unicode. |
properties | MapiPropertyCollection | קרא / כתיבה | מקבל או מטיל את הנכסים. |
recipients | list[MapiRecipient] | קרא / כתיבה | מקבלים או מחזיקים את המועמדים. |
attachments | list[MapiAttachment] | קרא / כתיבה | מקבל או מפרט את הקבצים. |
extra_streams | list[MsgStream] | קרא / כתיבה | מקבל או מטיל את הזרמים נוספים. |
extra_storages | list[MsgStorage] | קרא / כתיבה | מקבל או מטיל את אחסון נוסף. |
nameid_mapping | _NamedPropertyMapping | קרא / כתיבה | מקבל או מפרט את המפה הנקראת. |
major_version | int | קרא / כתיבה | מקבל או מפרט את הגרסה העיקרית. |
minor_version | int | קרא / כתיבה | מקבל או מפרט את הגרסה הקטנה. |
transaction_signature_number | int | קרא / כתיבה | קבל או קבע את מספר החתימה של העסקה. |
header_reserved_0 | bytes | קרא / כתיבה | מקבל או מטיל את הכותרת מוגדרת 0. |
header_reserved_1 | bytes | קרא / כתיבה | קבל או הקלד את הכותרת המוגנת 1. |
emit_store_support_mask | bool | קרא / כתיבה | מקבל או מטיל את מסכה תמיכה של החנות. |
emit_compatibility_defaults | bool | קרא / כתיבה | מקבל או מגדיר את הפסולת תאימות ההפצה. |
preserve_declared_header_counts | bool | קרא / כתיבה | מקבל או מטיל את הכותרת המוכרח מחשב. |
declared_next_recipient_id | `int | None` | קרא / כתיבה |
declared_next_attachment_id | `int | None` | קרא / כתיבה |
declared_recipient_count | `int | None` | קרא / כתיבה |
declared_attachment_count | `int | None` | קרא / כתיבה |
שיטות
| חתימה | תיאור |
|---|---|
| `from_file(path: Path | str, strict: bool)→“MapiMessage”` |
from_msg_document(document: MsgDocument) → "MapiMessage" | התקשר מ_msg_document על האינדקס הזה MapiMessage. |
from_email_message(email_message: EmailMessage, unicode_strings: bool) → "MapiMessage" | התקשר מ_email_message על הדוגמה הזו MapiMessage. |
create(subject: str, body: str, unicode_strings: bool) → "MapiMessage" | שיחות שנוצרו על פי האינדקס הזה MapiMessage. |
iter_properties() → Iterator[MapiProperty] | קוראים iter_properties על האינדקס הזה MapiMessage. |
iter_property_keys(storage_stream_id: int) → Iterator[tuple[int, int]] | קרא iter_property_keys על הדוגמה הזו MapiMessage. |
| `set_property(property_id: int | CommonMessagePropertyId |
| `get_property(property_id: int | CommonMessagePropertyId |
| `get_property_value(property_id: int | CommonMessagePropertyId |
| `set_named_property(named_property: MapiNamedProperty, property_type: int | PropertyTypeCode, value: Any, flags: int)→MapiProperty` |
| `get_named_property(named_property: MapiNamedProperty, property_type: int | None)→MapiProperty |
| `add_recipient(email_address: str, display_name: str | None, recipient_type: int)→MapiRecipient` |
| `add_attachment(filename: str, data: bytes, mime_type: str | None, content_id: str |
| `add_embedded_message_attachment(message: “MapiMessage”, filename: str | None, mime_type: str |
| `save(path: Path | str)` |
to_bytes() → bytes | קוראים ל_bytes על האינדקס הזה MapiMessage. |
to_email_message() → EmailMessage | התקשר ל_email_message על הדוגמה הזו MapiMessage. |
to_email_bytes() → bytes | התקשר ל_email_bytes על הדוגמה הזו MapiMessage. |
to_email_string() → str | התקשר ל_email_string על הדוגמה הזו MapiMessage. |
iter_attachments_info() → Iterator[MapiAttachment] | קרא iter_attachments_info על הדוגמה הזו MapiMessage. |
close() | צלצול קרוב על האינדקס הזה MapiMessage. |
to_msg_document() → MsgDocument | התקשר ל_msg_document על האינדקס הזה MapiMessage. |