Skip navigation links
org.netbeans.api.intent 1.8

Package org.netbeans.api.intent

API for working with Intents, abstract descriptions of intended operations.

See: Description

Package org.netbeans.api.intent Description

API for working with Intents, abstract descriptions of intended operations.

Intents can be used when we want to perform some standard operation and we believe that the environment (the IDE, some application) is capable of finding and choosing correct action for it.

The operations are specified as pair of action type and a URI. See example:

Intent i = new Intent(Intent.ACTION_VIEW, new URI("file://path/file.txt"));

We can execute an Intent to let the system choose to most appropriate action for the intent and invoke it:

i.execute();

Or we can get list of all available actions, display them somehow, and let the user select one of them:

Set<IntentAction> available = i.getIntentActions();
Skip navigation links
org.netbeans.api.intent 1.8