0
我工作的EWS的Java API,我想知道如果附件類型的Java EWS - 如何讓附件類型
- ItemAttachment
- FileAttachment的
像這樣的
if (attachment is ItemAttachment) // how to in Java api?
if (attachment is FileAttachment) // how to in Java api?
我工作的EWS的Java API,我想知道如果附件類型的Java EWS - 如何讓附件類型
像這樣的
if (attachment is ItemAttachment) // how to in Java api?
if (attachment is FileAttachment) // how to in Java api?
您可以使用instanceof
:
if (attachment instanceof ItemAttachment) {
...
}