protected int count(UserCustomCursor cursor) {
        int count = 0;
        try {
            count = cursor.getCount();
        } finally {
            cursor.close();
        }
        return count;
    }
protected int count ( UserCustomCursor cursor ) { int count = 0 ; try { count = cursor . getCount ( ) ; } finally { cursor . close ( ) ; } return count ; }
Get the count of the cursor and close it

@param cursor cursor
@return count