/** * Sends a message to the client to be presented to users, with possible * commands to execute */ public void sendActionableNotification(MessageType severity, String message, Object data, List<Command> commands) { ActionableNotification notification = new ActionableNotification().withSeverity(severity).withMessage(message).withData(data).withCommands(commands); sendActionableNotification(notification); }
TextDocumentIdentifier uri = new TextDocumentIdentifier(uriString); ActionableNotification updateProjectConfigurationNotification = new ActionableNotification().withSeverity(MessageType.Info) .withMessage("A build file was modified. Do you want to synchronize the Java classpath/configuration?").withCommands(asList(new Command("Never", cmd, asList(uri, FeatureStatus.disabled)), new Command("Now", cmd, asList(uri, FeatureStatus.interactive)), new Command("Always", cmd, asList(uri, FeatureStatus.automatic)))); client.sendActionableNotification(updateProjectConfigurationNotification);
ActionableNotification ignoreIncompleteClasspath = new ActionableNotification() .withSeverity(severity.toMessageType()) .withMessage(msg) .withCommands(Arrays.asList( new Command("More Information", "java.ignoreIncompleteClasspath.help", null),