@ SuppressWarnings ( "unchecked" ) public ArrayList < Notification > getByType ( Class < ? > type ) { List < ? > byType = this . getByType ( ) ; if ( type . isAssignableFrom ( InteractionNotification . class ) ) return ( ArrayList < Notification > ) byType . get ( 0 ) ; if ( type . isAssignableFrom ( ValueNotification . class ) ) return ( ArrayList < Notification > ) byType . get ( 1 ) ; return null ; }
Search for notifications that match the corresponding notifications realization .