Excluding Notes and Reminders from UIActivityViewController in Swift
<p>Does anybody know how to do this (code below) in Swift?
It's the first answer to this question <a href="https://stackoverflow.com/questions/31792506/how-to-exclude-notes-and-reminders-apps-from-the-uiactivityviewcontroller">How to exclude Notes and Reminders apps from the UIActivityViewController?</a></p>

<p>Header:</p>

<pre><code>@interface UIActivityViewController (Private)

- (BOOL)_shouldExcludeActivityType:(UIActivity*)activity;

@end

@interface ActivityViewController : UIActivityViewController

@end
</code></pre>

<p>Implementation:</p>

<pre><code>@implementation ActivityViewController

- (BOOL)_shouldExcludeActivityType:(UIActivity *)activity
{
    if ([[activity activityType] isEqualToString:@"com.apple.reminders.RemindersEditorExtension"] ||
        [[activity activityType] isEqualToString:@"com.apple.mobilenotes.SharingExtension"]) {
        return YES;
    }
    return [super _shouldExcludeActivityType:activity];
}
</code></pre>