Code example for WeakHashMap

Methods: containsKeyget

    private void storeInIconCache(String resourceUri, Drawable drawable) {
        if (drawable != null) {
            mOutsideDrawablesCache.put(resourceUri, drawable.getConstantState());
     * Gets the left-hand side icon that will be used for the current suggestion 
     * if the suggestion contains an icon column but no icon or a broken icon. 
     * @param cursor A cursor positioned at the current suggestion. 
     * @return A non-null drawable. 
    private Drawable getDefaultIcon1(Cursor cursor) {
        // Fall back to a default icon 
        return mContext.getPackageManager().getDefaultActivityIcon(); 
     * Gets the activity or application icon for an activity.