 protocol QuickActionSupport {
 
     @available(iOS 9.0, *)
-    func prepareForQuickAction(shortcut: Shortcut)
-
-}
-
-class QuickActions {
+    func prepareForQuickAction<T: ShortcutType>(shortcutType: T)
+
+}
+
+class QuickActions<T: ShortcutType> {
 
     let bundleIdentifier: String
 


}

struct Shortcut {

    let id: String
    let title: String
    let subtitle: String?
    let icon: ShortcutIcon?

    init(id: String, title: String, subtitle: String?, icon: ShortcutIcon) {
        self.id = id
        self.title = title
        self.subtitle = subtitle
        self.icon = icon

    @available(iOS 9.0, *)
    init(shortcutItem: UIApplicationShortcutItem) {
        if let range = shortcutItem.type.rangeOfCharacterFromSet(NSCharacterSet(charactersInString: "."), options: .BackwardsSearch) {
            type = shortcutItem.type.substringFromIndex(range.endIndex)
        }
        else {
            type = "unknown"
        }
        title = shortcutItem.localizedTitle
        subtitle = shortcutItem.localizedSubtitle
