Back to project page Arvutaja.
The source code is released under:
Apache License
If you think the Android project Arvutaja listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package ee.ioc.phon.android.arvutaja.command; // ww w . jav a2s . c o m import ee.ioc.phon.android.arvutaja.R; import android.app.SearchManager; import android.content.Intent; public class WebSearch extends DefaultCommand { public WebSearch(String command) { super(command); } public int getMessage() { return R.string.msgActionWebSearch; } @Override public Intent getIntent() throws CommandParseException { Intent intent = new Intent(Intent.ACTION_WEB_SEARCH); intent.putExtra(SearchManager.QUERY, getCommand()); return intent; } public static boolean isCommand(String command) { return command.contains("weather") || command.contains("current time"); } }