Package com.nineteendrops.tracdrops.client.api.search

Examples of com.nineteendrops.tracdrops.client.api.search.SearchQuery


        if(parameter == null){
            throw new TracException(MessageUtils.getMessage("core.parameter.not.found", "SimpleObject", this.getClass().getName()));
        }

        SearchQuery searchQuery = (SearchQuery)parameter;

        // check for mandatory fields
        String query = searchQuery.getQuery();
        if(query == null){
            query = "";
        }

        MultiParameter multiParameter = new MultiParameter();
        multiParameter.addParameter(query);

        ArrayList<String> listOfFilters = new ArrayList<String>();
        if(!searchQuery.isOnAll()){
            if(searchQuery.isOnTickets()) listOfFilters.add(SearchKeys.ON_TICKETS);
            if(searchQuery.isOnChangesets()) listOfFilters.add(SearchKeys.ON_CHANGESETS);
            if(searchQuery.isOnMilestones()) listOfFilters.add(SearchKeys.ON_MILESTONES);
            if(searchQuery.isOnWiki()) listOfFilters.add(SearchKeys.ON_WIKI);

            multiParameter.addParameter(Utils.fillVectorFromArrayList(listOfFilters));
        }

        return multiParameter;
View Full Code Here

TOP

Related Classes of com.nineteendrops.tracdrops.client.api.search.SearchQuery

Copyright © 2018 www.massapicom. 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.