Examples of UnifiedSearchServices


Examples of net.rim.device.api.unifiedsearch.UnifiedSearchServices

        } else {
            _displayables.removeAllElements();
        }

        SearchResponse results = null;
        final UnifiedSearchServices services =
                UnifiedSearchServices.getInstance();

        // Retrieve searchables
        final Vector vector =
                services.getDeviceSearchables(SearchableContentTypeConstantsInfo
                        .getAllContentTypes());
        final Searchable[] searchables = new Searchable[vector.size()];
        vector.copyInto(searchables);

        // Get search fields for each searchable
        final SearchField[][] searchFields = new SearchField[vector.size()][0];
        for (int i = 0; i < searchables.length; i++) {
            searchFields[i] = searchables[i].defineSupportedSearchFields();
        }

        // Get SearchResponse for keyword
        try {
            results = services.search(keyword, searchables, searchFields);
        } catch (final Exception e) {
            UnifiedSearchDemo.errorDialog(e.toString());
        }

        if (results != null) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.