File: attachments.html

package info (click to toggle)
python-exchangelib 5.6.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 13,364 kB
  • sloc: python: 25,367; sh: 6; makefile: 5
file content (903 lines) | stat: -rw-r--r-- 48,386 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, minimum-scale=1">
<meta name="generator" content="pdoc3 0.11.6">
<title>exchangelib.attachments API documentation</title>
<meta name="description" content="">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/10up-sanitize.css/13.0.0/sanitize.min.css" integrity="sha512-y1dtMcuvtTMJc1yPgEqF0ZjQbhnc/bFhyvIyVNb9Zk5mIGtqVaAB1Ttl28su8AvFMOY0EwRbAe+HCLqj6W7/KA==" crossorigin>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/10up-sanitize.css/13.0.0/typography.min.css" integrity="sha512-Y1DYSb995BAfxobCkKepB1BqJJTPrOp3zPL74AWFugHHmmdcvO+C48WLrUOlhGMc0QG7AE3f7gmvvcrmX2fDoA==" crossorigin>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.9.0/styles/default.min.css" crossorigin>
<style>:root{--highlight-color:#fe9}.flex{display:flex !important}body{line-height:1.5em}#content{padding:20px}#sidebar{padding:1.5em;overflow:hidden}#sidebar > *:last-child{margin-bottom:2cm}.http-server-breadcrumbs{font-size:130%;margin:0 0 15px 0}#footer{font-size:.75em;padding:5px 30px;border-top:1px solid #ddd;text-align:right}#footer p{margin:0 0 0 1em;display:inline-block}#footer p:last-child{margin-right:30px}h1,h2,h3,h4,h5{font-weight:300}h1{font-size:2.5em;line-height:1.1em}h2{font-size:1.75em;margin:2em 0 .50em 0}h3{font-size:1.4em;margin:1.6em 0 .7em 0}h4{margin:0;font-size:105%}h1:target,h2:target,h3:target,h4:target,h5:target,h6:target{background:var(--highlight-color);padding:.2em 0}a{color:#058;text-decoration:none;transition:color .2s ease-in-out}a:visited{color:#503}a:hover{color:#b62}.title code{font-weight:bold}h2[id^="header-"]{margin-top:2em}.ident{color:#900;font-weight:bold}pre code{font-size:.8em;line-height:1.4em;padding:1em;display:block}code{background:#f3f3f3;font-family:"DejaVu Sans Mono",monospace;padding:1px 4px;overflow-wrap:break-word}h1 code{background:transparent}pre{border-top:1px solid #ccc;border-bottom:1px solid #ccc;margin:1em 0}#http-server-module-list{display:flex;flex-flow:column}#http-server-module-list div{display:flex}#http-server-module-list dt{min-width:10%}#http-server-module-list p{margin-top:0}.toc ul,#index{list-style-type:none;margin:0;padding:0}#index code{background:transparent}#index h3{border-bottom:1px solid #ddd}#index ul{padding:0}#index h4{margin-top:.6em;font-weight:bold}@media (min-width:200ex){#index .two-column{column-count:2}}@media (min-width:300ex){#index .two-column{column-count:3}}dl{margin-bottom:2em}dl dl:last-child{margin-bottom:4em}dd{margin:0 0 1em 3em}#header-classes + dl > dd{margin-bottom:3em}dd dd{margin-left:2em}dd p{margin:10px 0}.name{background:#eee;font-size:.85em;padding:5px 10px;display:inline-block;min-width:40%}.name:hover{background:#e0e0e0}dt:target .name{background:var(--highlight-color)}.name > span:first-child{white-space:nowrap}.name.class > span:nth-child(2){margin-left:.4em}.inherited{color:#999;border-left:5px solid #eee;padding-left:1em}.inheritance em{font-style:normal;font-weight:bold}.desc h2{font-weight:400;font-size:1.25em}.desc h3{font-size:1em}.desc dt code{background:inherit}.source > summary,.git-link-div{color:#666;text-align:right;font-weight:400;font-size:.8em;text-transform:uppercase}.source summary > *{white-space:nowrap;cursor:pointer}.git-link{color:inherit;margin-left:1em}.source pre{max-height:500px;overflow:auto;margin:0}.source pre code{font-size:12px;overflow:visible;min-width:max-content}.hlist{list-style:none}.hlist li{display:inline}.hlist li:after{content:',\2002'}.hlist li:last-child:after{content:none}.hlist .hlist{display:inline;padding-left:1em}img{max-width:100%}td{padding:0 .5em}.admonition{padding:.1em 1em;margin:1em 0}.admonition-title{font-weight:bold}.admonition.note,.admonition.info,.admonition.important{background:#aef}.admonition.todo,.admonition.versionadded,.admonition.tip,.admonition.hint{background:#dfd}.admonition.warning,.admonition.versionchanged,.admonition.deprecated{background:#fd4}.admonition.error,.admonition.danger,.admonition.caution{background:lightpink}</style>
<style media="screen and (min-width: 700px)">@media screen and (min-width:700px){#sidebar{width:30%;height:100vh;overflow:auto;position:sticky;top:0}#content{width:70%;max-width:100ch;padding:3em 4em;border-left:1px solid #ddd}pre code{font-size:1em}.name{font-size:1em}main{display:flex;flex-direction:row-reverse;justify-content:flex-end}.toc ul ul,#index ul ul{padding-left:1em}.toc > ul > li{margin-top:.5em}}</style>
<style media="print">@media print{#sidebar h1{page-break-before:always}.source{display:none}}@media print{*{background:transparent !important;color:#000 !important;box-shadow:none !important;text-shadow:none !important}a[href]:after{content:" (" attr(href) ")";font-size:90%}a[href][title]:after{content:none}abbr[title]:after{content:" (" attr(title) ")"}.ir a:after,a[href^="javascript:"]:after,a[href^="#"]:after{content:""}pre,blockquote{border:1px solid #999;page-break-inside:avoid}thead{display:table-header-group}tr,img{page-break-inside:avoid}img{max-width:100% !important}@page{margin:0.5cm}p,h2,h3{orphans:3;widows:3}h1,h2,h3,h4,h5,h6{page-break-after:avoid}}</style>
<script defer src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.9.0/highlight.min.js" integrity="sha512-D9gUyxqja7hBtkWpPWGt9wfbfaMGVt9gnyCvYa+jojwwPHLCzUm5i8rpk7vD7wNee9bA35eYIjobYPaQuKS1MQ==" crossorigin></script>
<script>window.addEventListener('DOMContentLoaded', () => {
hljs.configure({languages: ['bash', 'css', 'diff', 'graphql', 'ini', 'javascript', 'json', 'plaintext', 'python', 'python-repl', 'rust', 'shell', 'sql', 'typescript', 'xml', 'yaml']});
hljs.highlightAll();
/* Collapse source docstrings */
setTimeout(() => {
[...document.querySelectorAll('.hljs.language-python > .hljs-string')]
.filter(el => el.innerHTML.length > 200 && ['"""', "'''"].includes(el.innerHTML.substring(0, 3)))
.forEach(el => {
let d = document.createElement('details');
d.classList.add('hljs-string');
d.innerHTML = '<summary>"""</summary>' + el.innerHTML.substring(3);
el.replaceWith(d);
});
}, 100);
})</script>
</head>
<body>
<main>
<article id="content">
<header>
<h1 class="title">Module <code>exchangelib.attachments</code></h1>
</header>
<section id="section-intro">
</section>
<section>
</section>
<section>
</section>
<section>
</section>
<section>
<h2 class="section-title" id="header-classes">Classes</h2>
<dl>
<dt id="exchangelib.attachments.Attachment"><code class="flex name class">
<span>class <span class="ident">Attachment</span></span>
<span>(</span><span>**kwargs)</span>
</code></dt>
<dd>
<details class="source">
<summary>
<span>Expand source code</span>
</summary>
<pre><code class="python">class Attachment(EWSElement, metaclass=EWSMeta):
    &#34;&#34;&#34;Base class for FileAttachment and ItemAttachment.&#34;&#34;&#34;

    attachment_id = EWSElementField(value_cls=AttachmentId)
    name = TextField(field_uri=&#34;Name&#34;)
    content_type = TextField(field_uri=&#34;ContentType&#34;)
    content_id = TextField(field_uri=&#34;ContentId&#34;)
    content_location = URIField(field_uri=&#34;ContentLocation&#34;)
    size = IntegerField(field_uri=&#34;Size&#34;, is_read_only=True)  # Attachment size in bytes
    last_modified_time = DateTimeField(field_uri=&#34;LastModifiedTime&#34;)
    is_inline = BooleanField(field_uri=&#34;IsInline&#34;)

    __slots__ = (&#34;parent_item&#34;,)

    def __init__(self, **kwargs):
        self.parent_item = kwargs.pop(&#34;parent_item&#34;, None)
        super().__init__(**kwargs)

    def clean(self, version=None):
        from .items import Item

        if self.parent_item is not None and not isinstance(self.parent_item, Item):
            raise InvalidTypeError(&#34;parent_item&#34;, self.parent_item, Item)
        if self.content_type is None and self.name is not None:
            self.content_type = mimetypes.guess_type(self.name)[0] or &#34;application/octet-stream&#34;
        super().clean(version=version)

    def attach(self):
        from .services import CreateAttachment

        # Adds this attachment to an item and updates the changekey of the parent item
        if self.attachment_id:
            raise ValueError(&#34;This attachment has already been created&#34;)
        if not self.parent_item or not self.parent_item.account:
            raise ValueError(f&#34;Parent item {self.parent_item} must have an account&#34;)
        item = CreateAttachment(account=self.parent_item.account).get(parent_item=self.parent_item, items=[self])
        attachment_id = item.attachment_id
        self.parent_item.changekey = attachment_id.root_changekey
        # EWS does not like receiving root_id and root_changekey on subsequent requests
        attachment_id.root_id = None
        attachment_id.root_changekey = None
        self.attachment_id = attachment_id

    def detach(self):
        from .services import DeleteAttachment

        # Deletes an attachment remotely and updates the changekey of the parent item
        if not self.attachment_id:
            raise ValueError(&#34;This attachment has not been created&#34;)
        if not self.parent_item or not self.parent_item.account:
            raise ValueError(f&#34;Parent item {self.parent_item} must have an account&#34;)
        DeleteAttachment(account=self.parent_item.account).get(items=[self.attachment_id])
        self.parent_item = None
        self.attachment_id = None

    def __hash__(self):
        if self.attachment_id:
            return hash(self.attachment_id)
        # Be careful to avoid recursion on the back-reference to the parent item
        return hash(tuple(getattr(self, f) for f in self._slots_keys if f != &#34;parent_item&#34;))

    def __repr__(self):
        args_str = &#34;, &#34;.join(
            f&#34;{f.name}={getattr(self, f.name)!r}&#34; for f in self.FIELDS if f.name not in (&#34;_item&#34;, &#34;_content&#34;)
        )
        return f&#34;{self.__class__.__name__}({args_str})&#34;</code></pre>
</details>
<div class="desc"><p>Base class for FileAttachment and ItemAttachment.</p></div>
<h3>Ancestors</h3>
<ul class="hlist">
<li><a title="exchangelib.properties.EWSElement" href="properties.html#exchangelib.properties.EWSElement">EWSElement</a></li>
</ul>
<h3>Subclasses</h3>
<ul class="hlist">
<li><a title="exchangelib.attachments.FileAttachment" href="#exchangelib.attachments.FileAttachment">FileAttachment</a></li>
<li><a title="exchangelib.attachments.ItemAttachment" href="#exchangelib.attachments.ItemAttachment">ItemAttachment</a></li>
</ul>
<h3>Instance variables</h3>
<dl>
<dt id="exchangelib.attachments.Attachment.attachment_id"><code class="name">var <span class="ident">attachment_id</span></code></dt>
<dd>
<div class="desc"><p>The type of the None singleton.</p></div>
</dd>
<dt id="exchangelib.attachments.Attachment.content_id"><code class="name">var <span class="ident">content_id</span></code></dt>
<dd>
<div class="desc"><p>The type of the None singleton.</p></div>
</dd>
<dt id="exchangelib.attachments.Attachment.content_location"><code class="name">var <span class="ident">content_location</span></code></dt>
<dd>
<div class="desc"><p>The type of the None singleton.</p></div>
</dd>
<dt id="exchangelib.attachments.Attachment.content_type"><code class="name">var <span class="ident">content_type</span></code></dt>
<dd>
<div class="desc"><p>The type of the None singleton.</p></div>
</dd>
<dt id="exchangelib.attachments.Attachment.is_inline"><code class="name">var <span class="ident">is_inline</span></code></dt>
<dd>
<div class="desc"><p>The type of the None singleton.</p></div>
</dd>
<dt id="exchangelib.attachments.Attachment.last_modified_time"><code class="name">var <span class="ident">last_modified_time</span></code></dt>
<dd>
<div class="desc"><p>The type of the None singleton.</p></div>
</dd>
<dt id="exchangelib.attachments.Attachment.name"><code class="name">var <span class="ident">name</span></code></dt>
<dd>
<div class="desc"><p>The type of the None singleton.</p></div>
</dd>
<dt id="exchangelib.attachments.Attachment.parent_item"><code class="name">var <span class="ident">parent_item</span></code></dt>
<dd>
<details class="source">
<summary>
<span>Expand source code</span>
</summary>
<pre><code class="python">class Attachment(EWSElement, metaclass=EWSMeta):
    &#34;&#34;&#34;Base class for FileAttachment and ItemAttachment.&#34;&#34;&#34;

    attachment_id = EWSElementField(value_cls=AttachmentId)
    name = TextField(field_uri=&#34;Name&#34;)
    content_type = TextField(field_uri=&#34;ContentType&#34;)
    content_id = TextField(field_uri=&#34;ContentId&#34;)
    content_location = URIField(field_uri=&#34;ContentLocation&#34;)
    size = IntegerField(field_uri=&#34;Size&#34;, is_read_only=True)  # Attachment size in bytes
    last_modified_time = DateTimeField(field_uri=&#34;LastModifiedTime&#34;)
    is_inline = BooleanField(field_uri=&#34;IsInline&#34;)

    __slots__ = (&#34;parent_item&#34;,)

    def __init__(self, **kwargs):
        self.parent_item = kwargs.pop(&#34;parent_item&#34;, None)
        super().__init__(**kwargs)

    def clean(self, version=None):
        from .items import Item

        if self.parent_item is not None and not isinstance(self.parent_item, Item):
            raise InvalidTypeError(&#34;parent_item&#34;, self.parent_item, Item)
        if self.content_type is None and self.name is not None:
            self.content_type = mimetypes.guess_type(self.name)[0] or &#34;application/octet-stream&#34;
        super().clean(version=version)

    def attach(self):
        from .services import CreateAttachment

        # Adds this attachment to an item and updates the changekey of the parent item
        if self.attachment_id:
            raise ValueError(&#34;This attachment has already been created&#34;)
        if not self.parent_item or not self.parent_item.account:
            raise ValueError(f&#34;Parent item {self.parent_item} must have an account&#34;)
        item = CreateAttachment(account=self.parent_item.account).get(parent_item=self.parent_item, items=[self])
        attachment_id = item.attachment_id
        self.parent_item.changekey = attachment_id.root_changekey
        # EWS does not like receiving root_id and root_changekey on subsequent requests
        attachment_id.root_id = None
        attachment_id.root_changekey = None
        self.attachment_id = attachment_id

    def detach(self):
        from .services import DeleteAttachment

        # Deletes an attachment remotely and updates the changekey of the parent item
        if not self.attachment_id:
            raise ValueError(&#34;This attachment has not been created&#34;)
        if not self.parent_item or not self.parent_item.account:
            raise ValueError(f&#34;Parent item {self.parent_item} must have an account&#34;)
        DeleteAttachment(account=self.parent_item.account).get(items=[self.attachment_id])
        self.parent_item = None
        self.attachment_id = None

    def __hash__(self):
        if self.attachment_id:
            return hash(self.attachment_id)
        # Be careful to avoid recursion on the back-reference to the parent item
        return hash(tuple(getattr(self, f) for f in self._slots_keys if f != &#34;parent_item&#34;))

    def __repr__(self):
        args_str = &#34;, &#34;.join(
            f&#34;{f.name}={getattr(self, f.name)!r}&#34; for f in self.FIELDS if f.name not in (&#34;_item&#34;, &#34;_content&#34;)
        )
        return f&#34;{self.__class__.__name__}({args_str})&#34;</code></pre>
</details>
<div class="desc"></div>
</dd>
<dt id="exchangelib.attachments.Attachment.size"><code class="name">var <span class="ident">size</span></code></dt>
<dd>
<div class="desc"><p>The type of the None singleton.</p></div>
</dd>
</dl>
<h3>Methods</h3>
<dl>
<dt id="exchangelib.attachments.Attachment.attach"><code class="name flex">
<span>def <span class="ident">attach</span></span>(<span>self)</span>
</code></dt>
<dd>
<details class="source">
<summary>
<span>Expand source code</span>
</summary>
<pre><code class="python">def attach(self):
    from .services import CreateAttachment

    # Adds this attachment to an item and updates the changekey of the parent item
    if self.attachment_id:
        raise ValueError(&#34;This attachment has already been created&#34;)
    if not self.parent_item or not self.parent_item.account:
        raise ValueError(f&#34;Parent item {self.parent_item} must have an account&#34;)
    item = CreateAttachment(account=self.parent_item.account).get(parent_item=self.parent_item, items=[self])
    attachment_id = item.attachment_id
    self.parent_item.changekey = attachment_id.root_changekey
    # EWS does not like receiving root_id and root_changekey on subsequent requests
    attachment_id.root_id = None
    attachment_id.root_changekey = None
    self.attachment_id = attachment_id</code></pre>
</details>
<div class="desc"></div>
</dd>
<dt id="exchangelib.attachments.Attachment.clean"><code class="name flex">
<span>def <span class="ident">clean</span></span>(<span>self, version=None)</span>
</code></dt>
<dd>
<details class="source">
<summary>
<span>Expand source code</span>
</summary>
<pre><code class="python">def clean(self, version=None):
    from .items import Item

    if self.parent_item is not None and not isinstance(self.parent_item, Item):
        raise InvalidTypeError(&#34;parent_item&#34;, self.parent_item, Item)
    if self.content_type is None and self.name is not None:
        self.content_type = mimetypes.guess_type(self.name)[0] or &#34;application/octet-stream&#34;
    super().clean(version=version)</code></pre>
</details>
<div class="desc"></div>
</dd>
<dt id="exchangelib.attachments.Attachment.detach"><code class="name flex">
<span>def <span class="ident">detach</span></span>(<span>self)</span>
</code></dt>
<dd>
<details class="source">
<summary>
<span>Expand source code</span>
</summary>
<pre><code class="python">def detach(self):
    from .services import DeleteAttachment

    # Deletes an attachment remotely and updates the changekey of the parent item
    if not self.attachment_id:
        raise ValueError(&#34;This attachment has not been created&#34;)
    if not self.parent_item or not self.parent_item.account:
        raise ValueError(f&#34;Parent item {self.parent_item} must have an account&#34;)
    DeleteAttachment(account=self.parent_item.account).get(items=[self.attachment_id])
    self.parent_item = None
    self.attachment_id = None</code></pre>
</details>
<div class="desc"></div>
</dd>
</dl>
<h3>Inherited members</h3>
<ul class="hlist">
<li><code><b><a title="exchangelib.properties.EWSElement" href="properties.html#exchangelib.properties.EWSElement">EWSElement</a></b></code>:
<ul class="hlist">
<li><code><a title="exchangelib.properties.EWSElement.ELEMENT_NAME" href="properties.html#exchangelib.properties.EWSElement.ELEMENT_NAME">ELEMENT_NAME</a></code></li>
<li><code><a title="exchangelib.properties.EWSElement.FIELDS" href="properties.html#exchangelib.properties.EWSElement.FIELDS">FIELDS</a></code></li>
<li><code><a title="exchangelib.properties.EWSElement.NAMESPACE" href="properties.html#exchangelib.properties.EWSElement.NAMESPACE">NAMESPACE</a></code></li>
<li><code><a title="exchangelib.properties.EWSElement.add_field" href="properties.html#exchangelib.properties.EWSElement.add_field">add_field</a></code></li>
<li><code><a title="exchangelib.properties.EWSElement.remove_field" href="properties.html#exchangelib.properties.EWSElement.remove_field">remove_field</a></code></li>
<li><code><a title="exchangelib.properties.EWSElement.supported_fields" href="properties.html#exchangelib.properties.EWSElement.supported_fields">supported_fields</a></code></li>
<li><code><a title="exchangelib.properties.EWSElement.validate_field" href="properties.html#exchangelib.properties.EWSElement.validate_field">validate_field</a></code></li>
</ul>
</li>
</ul>
</dd>
<dt id="exchangelib.attachments.AttachmentId"><code class="flex name class">
<span>class <span class="ident">AttachmentId</span></span>
<span>(</span><span>*args, **kwargs)</span>
</code></dt>
<dd>
<details class="source">
<summary>
<span>Expand source code</span>
</summary>
<pre><code class="python">class AttachmentId(BaseItemId):
    &#34;&#34;&#34;MSDN: https://docs.microsoft.com/en-us/exchange/client-developer/web-service-reference/attachmentid&#34;&#34;&#34;

    ELEMENT_NAME = &#34;AttachmentId&#34;

    ID_ATTR = &#34;Id&#34;
    ROOT_ID_ATTR = &#34;RootItemId&#34;
    ROOT_CHANGEKEY_ATTR = &#34;RootItemChangeKey&#34;

    id = IdField(field_uri=ID_ATTR, is_required=True)
    root_id = IdField(field_uri=ROOT_ID_ATTR)
    root_changekey = IdField(field_uri=ROOT_CHANGEKEY_ATTR)</code></pre>
</details>
<div class="desc"><p>MSDN: <a href="https://docs.microsoft.com/en-us/exchange/client-developer/web-service-reference/attachmentid">https://docs.microsoft.com/en-us/exchange/client-developer/web-service-reference/attachmentid</a></p></div>
<h3>Ancestors</h3>
<ul class="hlist">
<li><a title="exchangelib.properties.BaseItemId" href="properties.html#exchangelib.properties.BaseItemId">BaseItemId</a></li>
<li><a title="exchangelib.properties.EWSElement" href="properties.html#exchangelib.properties.EWSElement">EWSElement</a></li>
</ul>
<h3>Class variables</h3>
<dl>
<dt id="exchangelib.attachments.AttachmentId.ROOT_CHANGEKEY_ATTR"><code class="name">var <span class="ident">ROOT_CHANGEKEY_ATTR</span></code></dt>
<dd>
<div class="desc"><p>The type of the None singleton.</p></div>
</dd>
<dt id="exchangelib.attachments.AttachmentId.ROOT_ID_ATTR"><code class="name">var <span class="ident">ROOT_ID_ATTR</span></code></dt>
<dd>
<div class="desc"><p>The type of the None singleton.</p></div>
</dd>
</dl>
<h3>Instance variables</h3>
<dl>
<dt id="exchangelib.attachments.AttachmentId.id"><code class="name">var <span class="ident">id</span></code></dt>
<dd>
<div class="desc"><p>The type of the None singleton.</p></div>
</dd>
<dt id="exchangelib.attachments.AttachmentId.root_changekey"><code class="name">var <span class="ident">root_changekey</span></code></dt>
<dd>
<div class="desc"><p>The type of the None singleton.</p></div>
</dd>
<dt id="exchangelib.attachments.AttachmentId.root_id"><code class="name">var <span class="ident">root_id</span></code></dt>
<dd>
<div class="desc"><p>The type of the None singleton.</p></div>
</dd>
</dl>
<h3>Inherited members</h3>
<ul class="hlist">
<li><code><b><a title="exchangelib.properties.BaseItemId" href="properties.html#exchangelib.properties.BaseItemId">BaseItemId</a></b></code>:
<ul class="hlist">
<li><code><a title="exchangelib.properties.BaseItemId.CHANGEKEY_ATTR" href="properties.html#exchangelib.properties.BaseItemId.CHANGEKEY_ATTR">CHANGEKEY_ATTR</a></code></li>
<li><code><a title="exchangelib.properties.BaseItemId.ELEMENT_NAME" href="properties.html#exchangelib.properties.EWSElement.ELEMENT_NAME">ELEMENT_NAME</a></code></li>
<li><code><a title="exchangelib.properties.BaseItemId.FIELDS" href="properties.html#exchangelib.properties.EWSElement.FIELDS">FIELDS</a></code></li>
<li><code><a title="exchangelib.properties.BaseItemId.ID_ATTR" href="properties.html#exchangelib.properties.BaseItemId.ID_ATTR">ID_ATTR</a></code></li>
<li><code><a title="exchangelib.properties.BaseItemId.NAMESPACE" href="properties.html#exchangelib.properties.EWSElement.NAMESPACE">NAMESPACE</a></code></li>
<li><code><a title="exchangelib.properties.BaseItemId.add_field" href="properties.html#exchangelib.properties.EWSElement.add_field">add_field</a></code></li>
<li><code><a title="exchangelib.properties.BaseItemId.remove_field" href="properties.html#exchangelib.properties.EWSElement.remove_field">remove_field</a></code></li>
<li><code><a title="exchangelib.properties.BaseItemId.supported_fields" href="properties.html#exchangelib.properties.EWSElement.supported_fields">supported_fields</a></code></li>
<li><code><a title="exchangelib.properties.BaseItemId.validate_field" href="properties.html#exchangelib.properties.EWSElement.validate_field">validate_field</a></code></li>
</ul>
</li>
</ul>
</dd>
<dt id="exchangelib.attachments.FileAttachment"><code class="flex name class">
<span>class <span class="ident">FileAttachment</span></span>
<span>(</span><span>**kwargs)</span>
</code></dt>
<dd>
<details class="source">
<summary>
<span>Expand source code</span>
</summary>
<pre><code class="python">class FileAttachment(Attachment):
    &#34;&#34;&#34;MSDN: https://docs.microsoft.com/en-us/exchange/client-developer/web-service-reference/fileattachment&#34;&#34;&#34;

    ELEMENT_NAME = &#34;FileAttachment&#34;

    is_contact_photo = BooleanField(field_uri=&#34;IsContactPhoto&#34;)
    _content = Base64Field(field_uri=&#34;Content&#34;)

    __slots__ = (&#34;_fp&#34;,)

    def __init__(self, **kwargs):
        kwargs[&#34;_content&#34;] = kwargs.pop(&#34;content&#34;, None)
        super().__init__(**kwargs)
        self._fp = None

    @property
    def fp(self):
        # Return a file-like object for the content. This avoids creating multiple in-memory copies of the content.
        if self._fp is None:
            self._init_fp()
        return self._fp

    def _init_fp(self):
        # Create a file-like object for the attachment content. We try hard to reduce memory consumption, so we never
        # store the full attachment content in-memory.
        if not self.parent_item or not self.parent_item.account:
            raise ValueError(f&#34;{self.__class__.__name__} must have an account&#34;)
        self._fp = FileAttachmentIO(attachment=self)

    @property
    def content(self):
        &#34;&#34;&#34;Return the attachment content. Stores a local copy of the content in case you want to upload the attachment
        again later.
        &#34;&#34;&#34;
        if self.attachment_id is None:
            return self._content
        if self._content is not None:
            return self._content
        # We have an ID to the data but still haven&#39;t called GetAttachment to get the actual data. Do that now.
        with self.fp as fp:
            self._content = fp.read()
        return self._content

    @content.setter
    def content(self, value):
        &#34;&#34;&#34;Replace the attachment content.&#34;&#34;&#34;
        if not isinstance(value, bytes):
            raise InvalidTypeError(&#34;value&#34;, value, bytes)
        self._content = value

    @classmethod
    def from_xml(cls, elem, account):
        kwargs = {f.name: f.from_xml(elem=elem, account=account) for f in cls.FIELDS}
        kwargs[&#34;content&#34;] = kwargs.pop(&#34;_content&#34;)
        cls._clear(elem)
        return cls(**kwargs)

    def to_xml(self, version):
        self._content = self.content  # Make sure content is available, to avoid ErrorRequiredPropertyMissing
        return super().to_xml(version=version)

    def __getstate__(self):
        # The fp does not need to be pickled
        state = {k: getattr(self, k) for k in self._slots_keys}
        del state[&#34;_fp&#34;]
        return state

    def __setstate__(self, state):
        # Restore the fp
        for k in self._slots_keys:
            setattr(self, k, state.get(k))
        self._fp = None</code></pre>
</details>
<div class="desc"><p>MSDN: <a href="https://docs.microsoft.com/en-us/exchange/client-developer/web-service-reference/fileattachment">https://docs.microsoft.com/en-us/exchange/client-developer/web-service-reference/fileattachment</a></p></div>
<h3>Ancestors</h3>
<ul class="hlist">
<li><a title="exchangelib.attachments.Attachment" href="#exchangelib.attachments.Attachment">Attachment</a></li>
<li><a title="exchangelib.properties.EWSElement" href="properties.html#exchangelib.properties.EWSElement">EWSElement</a></li>
</ul>
<h3>Static methods</h3>
<dl>
<dt id="exchangelib.attachments.FileAttachment.from_xml"><code class="name flex">
<span>def <span class="ident">from_xml</span></span>(<span>elem, account)</span>
</code></dt>
<dd>
<div class="desc"></div>
</dd>
</dl>
<h3>Instance variables</h3>
<dl>
<dt id="exchangelib.attachments.FileAttachment.content"><code class="name">prop <span class="ident">content</span></code></dt>
<dd>
<details class="source">
<summary>
<span>Expand source code</span>
</summary>
<pre><code class="python">@property
def content(self):
    &#34;&#34;&#34;Return the attachment content. Stores a local copy of the content in case you want to upload the attachment
    again later.
    &#34;&#34;&#34;
    if self.attachment_id is None:
        return self._content
    if self._content is not None:
        return self._content
    # We have an ID to the data but still haven&#39;t called GetAttachment to get the actual data. Do that now.
    with self.fp as fp:
        self._content = fp.read()
    return self._content</code></pre>
</details>
<div class="desc"><p>Return the attachment content. Stores a local copy of the content in case you want to upload the attachment
again later.</p></div>
</dd>
<dt id="exchangelib.attachments.FileAttachment.fp"><code class="name">prop <span class="ident">fp</span></code></dt>
<dd>
<details class="source">
<summary>
<span>Expand source code</span>
</summary>
<pre><code class="python">@property
def fp(self):
    # Return a file-like object for the content. This avoids creating multiple in-memory copies of the content.
    if self._fp is None:
        self._init_fp()
    return self._fp</code></pre>
</details>
<div class="desc"></div>
</dd>
<dt id="exchangelib.attachments.FileAttachment.is_contact_photo"><code class="name">var <span class="ident">is_contact_photo</span></code></dt>
<dd>
<div class="desc"><p>The type of the None singleton.</p></div>
</dd>
</dl>
<h3>Methods</h3>
<dl>
<dt id="exchangelib.attachments.FileAttachment.to_xml"><code class="name flex">
<span>def <span class="ident">to_xml</span></span>(<span>self, version)</span>
</code></dt>
<dd>
<details class="source">
<summary>
<span>Expand source code</span>
</summary>
<pre><code class="python">def to_xml(self, version):
    self._content = self.content  # Make sure content is available, to avoid ErrorRequiredPropertyMissing
    return super().to_xml(version=version)</code></pre>
</details>
<div class="desc"></div>
</dd>
</dl>
<h3>Inherited members</h3>
<ul class="hlist">
<li><code><b><a title="exchangelib.attachments.Attachment" href="#exchangelib.attachments.Attachment">Attachment</a></b></code>:
<ul class="hlist">
<li><code><a title="exchangelib.attachments.Attachment.ELEMENT_NAME" href="properties.html#exchangelib.properties.EWSElement.ELEMENT_NAME">ELEMENT_NAME</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.FIELDS" href="properties.html#exchangelib.properties.EWSElement.FIELDS">FIELDS</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.NAMESPACE" href="properties.html#exchangelib.properties.EWSElement.NAMESPACE">NAMESPACE</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.add_field" href="properties.html#exchangelib.properties.EWSElement.add_field">add_field</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.attachment_id" href="#exchangelib.attachments.Attachment.attachment_id">attachment_id</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.content_id" href="#exchangelib.attachments.Attachment.content_id">content_id</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.content_location" href="#exchangelib.attachments.Attachment.content_location">content_location</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.content_type" href="#exchangelib.attachments.Attachment.content_type">content_type</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.is_inline" href="#exchangelib.attachments.Attachment.is_inline">is_inline</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.last_modified_time" href="#exchangelib.attachments.Attachment.last_modified_time">last_modified_time</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.name" href="#exchangelib.attachments.Attachment.name">name</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.remove_field" href="properties.html#exchangelib.properties.EWSElement.remove_field">remove_field</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.size" href="#exchangelib.attachments.Attachment.size">size</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.supported_fields" href="properties.html#exchangelib.properties.EWSElement.supported_fields">supported_fields</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.validate_field" href="properties.html#exchangelib.properties.EWSElement.validate_field">validate_field</a></code></li>
</ul>
</li>
</ul>
</dd>
<dt id="exchangelib.attachments.FileAttachmentIO"><code class="flex name class">
<span>class <span class="ident">FileAttachmentIO</span></span>
<span>(</span><span>attachment)</span>
</code></dt>
<dd>
<details class="source">
<summary>
<span>Expand source code</span>
</summary>
<pre><code class="python">class FileAttachmentIO(io.RawIOBase):
    &#34;&#34;&#34;A BytesIO where the stream of data comes from the GetAttachment service.&#34;&#34;&#34;

    def __init__(self, attachment):
        self._attachment = attachment
        self._stream = None
        self._overflow = None

    def readable(self):
        return True

    @property
    def closed(self):
        return self._stream is None

    def readinto(self, b):
        buf_size = len(b)  # We can&#39;t return more than l bytes
        try:
            chunk = self._overflow or next(self._stream)
        except StopIteration:
            return 0
        else:
            output, self._overflow = chunk[:buf_size], chunk[buf_size:]
            b[: len(output)] = output
            return len(output)

    def __enter__(self):
        from .services import GetAttachment

        self._stream = GetAttachment(account=self._attachment.parent_item.account).stream_file_content(
            attachment_id=self._attachment.attachment_id
        )
        self._overflow = None
        return io.BufferedReader(self, buffer_size=io.DEFAULT_BUFFER_SIZE)

    def __exit__(self, *args, **kwargs):
        self._stream = None
        self._overflow = None</code></pre>
</details>
<div class="desc"><p>A BytesIO where the stream of data comes from the GetAttachment service.</p></div>
<h3>Ancestors</h3>
<ul class="hlist">
<li>io.RawIOBase</li>
<li>_io._RawIOBase</li>
<li>io.IOBase</li>
<li>_io._IOBase</li>
</ul>
<h3>Instance variables</h3>
<dl>
<dt id="exchangelib.attachments.FileAttachmentIO.closed"><code class="name">prop <span class="ident">closed</span></code></dt>
<dd>
<details class="source">
<summary>
<span>Expand source code</span>
</summary>
<pre><code class="python">@property
def closed(self):
    return self._stream is None</code></pre>
</details>
<div class="desc"></div>
</dd>
</dl>
<h3>Methods</h3>
<dl>
<dt id="exchangelib.attachments.FileAttachmentIO.readable"><code class="name flex">
<span>def <span class="ident">readable</span></span>(<span>self)</span>
</code></dt>
<dd>
<details class="source">
<summary>
<span>Expand source code</span>
</summary>
<pre><code class="python">def readable(self):
    return True</code></pre>
</details>
<div class="desc"><p>Return whether object was opened for reading.</p>
<p>If False, read() will raise OSError.</p></div>
</dd>
<dt id="exchangelib.attachments.FileAttachmentIO.readinto"><code class="name flex">
<span>def <span class="ident">readinto</span></span>(<span>self, b)</span>
</code></dt>
<dd>
<details class="source">
<summary>
<span>Expand source code</span>
</summary>
<pre><code class="python">def readinto(self, b):
    buf_size = len(b)  # We can&#39;t return more than l bytes
    try:
        chunk = self._overflow or next(self._stream)
    except StopIteration:
        return 0
    else:
        output, self._overflow = chunk[:buf_size], chunk[buf_size:]
        b[: len(output)] = output
        return len(output)</code></pre>
</details>
<div class="desc"></div>
</dd>
</dl>
</dd>
<dt id="exchangelib.attachments.ItemAttachment"><code class="flex name class">
<span>class <span class="ident">ItemAttachment</span></span>
<span>(</span><span>**kwargs)</span>
</code></dt>
<dd>
<details class="source">
<summary>
<span>Expand source code</span>
</summary>
<pre><code class="python">class ItemAttachment(Attachment):
    &#34;&#34;&#34;MSDN: https://docs.microsoft.com/en-us/exchange/client-developer/web-service-reference/itemattachment&#34;&#34;&#34;

    ELEMENT_NAME = &#34;ItemAttachment&#34;

    _item = ItemField(field_uri=&#34;Item&#34;)

    def __init__(self, **kwargs):
        kwargs[&#34;_item&#34;] = kwargs.pop(&#34;item&#34;, None)
        super().__init__(**kwargs)

    @property
    def item(self):
        from .folders import BaseFolder
        from .services import GetAttachment

        if self.attachment_id is None:
            return self._item
        if self._item is not None:
            return self._item
        # We have an ID to the data but still haven&#39;t called GetAttachment to get the actual data. Do that now.
        if not self.parent_item or not self.parent_item.account:
            raise ValueError(f&#34;{self.__class__.__name__} must have an account&#34;)
        additional_fields = {
            FieldPath(field=f) for f in BaseFolder.allowed_item_fields(version=self.parent_item.account.version)
        }
        attachment = GetAttachment(account=self.parent_item.account).get(
            items=[self.attachment_id],
            include_mime_content=True,
            body_type=None,
            filter_html_content=None,
            additional_fields=additional_fields,
        )
        self._item = attachment.item
        return self._item

    @item.setter
    def item(self, value):
        from .items import Item

        if not isinstance(value, Item):
            raise InvalidTypeError(&#34;value&#34;, value, Item)
        self._item = value

    @classmethod
    def from_xml(cls, elem, account):
        kwargs = {f.name: f.from_xml(elem=elem, account=account) for f in cls.FIELDS}
        kwargs[&#34;item&#34;] = kwargs.pop(&#34;_item&#34;)
        cls._clear(elem)
        return cls(**kwargs)</code></pre>
</details>
<div class="desc"><p>MSDN: <a href="https://docs.microsoft.com/en-us/exchange/client-developer/web-service-reference/itemattachment">https://docs.microsoft.com/en-us/exchange/client-developer/web-service-reference/itemattachment</a></p></div>
<h3>Ancestors</h3>
<ul class="hlist">
<li><a title="exchangelib.attachments.Attachment" href="#exchangelib.attachments.Attachment">Attachment</a></li>
<li><a title="exchangelib.properties.EWSElement" href="properties.html#exchangelib.properties.EWSElement">EWSElement</a></li>
</ul>
<h3>Static methods</h3>
<dl>
<dt id="exchangelib.attachments.ItemAttachment.from_xml"><code class="name flex">
<span>def <span class="ident">from_xml</span></span>(<span>elem, account)</span>
</code></dt>
<dd>
<div class="desc"></div>
</dd>
</dl>
<h3>Instance variables</h3>
<dl>
<dt id="exchangelib.attachments.ItemAttachment.item"><code class="name">prop <span class="ident">item</span></code></dt>
<dd>
<details class="source">
<summary>
<span>Expand source code</span>
</summary>
<pre><code class="python">@property
def item(self):
    from .folders import BaseFolder
    from .services import GetAttachment

    if self.attachment_id is None:
        return self._item
    if self._item is not None:
        return self._item
    # We have an ID to the data but still haven&#39;t called GetAttachment to get the actual data. Do that now.
    if not self.parent_item or not self.parent_item.account:
        raise ValueError(f&#34;{self.__class__.__name__} must have an account&#34;)
    additional_fields = {
        FieldPath(field=f) for f in BaseFolder.allowed_item_fields(version=self.parent_item.account.version)
    }
    attachment = GetAttachment(account=self.parent_item.account).get(
        items=[self.attachment_id],
        include_mime_content=True,
        body_type=None,
        filter_html_content=None,
        additional_fields=additional_fields,
    )
    self._item = attachment.item
    return self._item</code></pre>
</details>
<div class="desc"></div>
</dd>
</dl>
<h3>Inherited members</h3>
<ul class="hlist">
<li><code><b><a title="exchangelib.attachments.Attachment" href="#exchangelib.attachments.Attachment">Attachment</a></b></code>:
<ul class="hlist">
<li><code><a title="exchangelib.attachments.Attachment.ELEMENT_NAME" href="properties.html#exchangelib.properties.EWSElement.ELEMENT_NAME">ELEMENT_NAME</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.FIELDS" href="properties.html#exchangelib.properties.EWSElement.FIELDS">FIELDS</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.NAMESPACE" href="properties.html#exchangelib.properties.EWSElement.NAMESPACE">NAMESPACE</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.add_field" href="properties.html#exchangelib.properties.EWSElement.add_field">add_field</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.attachment_id" href="#exchangelib.attachments.Attachment.attachment_id">attachment_id</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.content_id" href="#exchangelib.attachments.Attachment.content_id">content_id</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.content_location" href="#exchangelib.attachments.Attachment.content_location">content_location</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.content_type" href="#exchangelib.attachments.Attachment.content_type">content_type</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.is_inline" href="#exchangelib.attachments.Attachment.is_inline">is_inline</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.last_modified_time" href="#exchangelib.attachments.Attachment.last_modified_time">last_modified_time</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.name" href="#exchangelib.attachments.Attachment.name">name</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.remove_field" href="properties.html#exchangelib.properties.EWSElement.remove_field">remove_field</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.size" href="#exchangelib.attachments.Attachment.size">size</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.supported_fields" href="properties.html#exchangelib.properties.EWSElement.supported_fields">supported_fields</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.validate_field" href="properties.html#exchangelib.properties.EWSElement.validate_field">validate_field</a></code></li>
</ul>
</li>
</ul>
</dd>
</dl>
</section>
</article>
<nav id="sidebar">
<div class="toc">
<ul></ul>
</div>
<ul id="index">
<li><h3>Super-module</h3>
<ul>
<li><code><a title="exchangelib" href="index.html">exchangelib</a></code></li>
</ul>
</li>
<li><h3><a href="#header-classes">Classes</a></h3>
<ul>
<li>
<h4><code><a title="exchangelib.attachments.Attachment" href="#exchangelib.attachments.Attachment">Attachment</a></code></h4>
<ul class="two-column">
<li><code><a title="exchangelib.attachments.Attachment.attach" href="#exchangelib.attachments.Attachment.attach">attach</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.attachment_id" href="#exchangelib.attachments.Attachment.attachment_id">attachment_id</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.clean" href="#exchangelib.attachments.Attachment.clean">clean</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.content_id" href="#exchangelib.attachments.Attachment.content_id">content_id</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.content_location" href="#exchangelib.attachments.Attachment.content_location">content_location</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.content_type" href="#exchangelib.attachments.Attachment.content_type">content_type</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.detach" href="#exchangelib.attachments.Attachment.detach">detach</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.is_inline" href="#exchangelib.attachments.Attachment.is_inline">is_inline</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.last_modified_time" href="#exchangelib.attachments.Attachment.last_modified_time">last_modified_time</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.name" href="#exchangelib.attachments.Attachment.name">name</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.parent_item" href="#exchangelib.attachments.Attachment.parent_item">parent_item</a></code></li>
<li><code><a title="exchangelib.attachments.Attachment.size" href="#exchangelib.attachments.Attachment.size">size</a></code></li>
</ul>
</li>
<li>
<h4><code><a title="exchangelib.attachments.AttachmentId" href="#exchangelib.attachments.AttachmentId">AttachmentId</a></code></h4>
<ul class="">
<li><code><a title="exchangelib.attachments.AttachmentId.ROOT_CHANGEKEY_ATTR" href="#exchangelib.attachments.AttachmentId.ROOT_CHANGEKEY_ATTR">ROOT_CHANGEKEY_ATTR</a></code></li>
<li><code><a title="exchangelib.attachments.AttachmentId.ROOT_ID_ATTR" href="#exchangelib.attachments.AttachmentId.ROOT_ID_ATTR">ROOT_ID_ATTR</a></code></li>
<li><code><a title="exchangelib.attachments.AttachmentId.id" href="#exchangelib.attachments.AttachmentId.id">id</a></code></li>
<li><code><a title="exchangelib.attachments.AttachmentId.root_changekey" href="#exchangelib.attachments.AttachmentId.root_changekey">root_changekey</a></code></li>
<li><code><a title="exchangelib.attachments.AttachmentId.root_id" href="#exchangelib.attachments.AttachmentId.root_id">root_id</a></code></li>
</ul>
</li>
<li>
<h4><code><a title="exchangelib.attachments.FileAttachment" href="#exchangelib.attachments.FileAttachment">FileAttachment</a></code></h4>
<ul class="">
<li><code><a title="exchangelib.attachments.FileAttachment.content" href="#exchangelib.attachments.FileAttachment.content">content</a></code></li>
<li><code><a title="exchangelib.attachments.FileAttachment.fp" href="#exchangelib.attachments.FileAttachment.fp">fp</a></code></li>
<li><code><a title="exchangelib.attachments.FileAttachment.from_xml" href="#exchangelib.attachments.FileAttachment.from_xml">from_xml</a></code></li>
<li><code><a title="exchangelib.attachments.FileAttachment.is_contact_photo" href="#exchangelib.attachments.FileAttachment.is_contact_photo">is_contact_photo</a></code></li>
<li><code><a title="exchangelib.attachments.FileAttachment.to_xml" href="#exchangelib.attachments.FileAttachment.to_xml">to_xml</a></code></li>
</ul>
</li>
<li>
<h4><code><a title="exchangelib.attachments.FileAttachmentIO" href="#exchangelib.attachments.FileAttachmentIO">FileAttachmentIO</a></code></h4>
<ul class="">
<li><code><a title="exchangelib.attachments.FileAttachmentIO.closed" href="#exchangelib.attachments.FileAttachmentIO.closed">closed</a></code></li>
<li><code><a title="exchangelib.attachments.FileAttachmentIO.readable" href="#exchangelib.attachments.FileAttachmentIO.readable">readable</a></code></li>
<li><code><a title="exchangelib.attachments.FileAttachmentIO.readinto" href="#exchangelib.attachments.FileAttachmentIO.readinto">readinto</a></code></li>
</ul>
</li>
<li>
<h4><code><a title="exchangelib.attachments.ItemAttachment" href="#exchangelib.attachments.ItemAttachment">ItemAttachment</a></code></h4>
<ul class="">
<li><code><a title="exchangelib.attachments.ItemAttachment.from_xml" href="#exchangelib.attachments.ItemAttachment.from_xml">from_xml</a></code></li>
<li><code><a title="exchangelib.attachments.ItemAttachment.item" href="#exchangelib.attachments.ItemAttachment.item">item</a></code></li>
</ul>
</li>
</ul>
</li>
</ul>
</nav>
</main>
<footer id="footer">
<p>Generated by <a href="https://pdoc3.github.io/pdoc" title="pdoc: Python API documentation generator"><cite>pdoc</cite> 0.11.6</a>.</p>
</footer>
</body>
</html>