Skip to content

Commit 9665570

Browse files
Richard Domanderctrueden
authored andcommitted
UserInterface: improve javadoc
Signed-off-by: Curtis Rueden <ctrueden@wisc.edu>
1 parent e20e90f commit 9665570

File tree

1 file changed

+22
-9
lines changed

1 file changed

+22
-9
lines changed

src/main/java/org/scijava/ui/UserInterface.java

Lines changed: 22 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@
5050
* implementing this interface, it is encouraged to instead extend
5151
* {@link AbstractUserInterface}, for convenience.
5252
* </p>
53-
*
53+
*
5454
* @author Curtis Rueden
5555
* @see Plugin
5656
* @see UIService
@@ -74,7 +74,7 @@ public interface UserInterface extends RichPlugin, Disposable {
7474

7575
/**
7676
* Shows the object onscreen using an appropriate UI widget.
77-
*
77+
*
7878
* @param name The name to use when displaying the object.
7979
* @param o The object to be displayed.
8080
*/
@@ -83,7 +83,10 @@ public interface UserInterface extends RichPlugin, Disposable {
8383
/** Shows the display onscreen using an appropriate UI widget. */
8484
void show(Display<?> display);
8585

86-
/** Gets the desktop, for use with multi-document interfaces (MDI). */
86+
/**
87+
* Gets the desktop, for use with multi-document interfaces (MDI), or null if
88+
* not applicable.
89+
*/
8790
Desktop getDesktop();
8891

8992
/** Gets the main SciJava application frame, or null if not applicable. */
@@ -98,15 +101,21 @@ public interface UserInterface extends RichPlugin, Disposable {
98101
/** Gets the main SciJava console pane, or null if not applicable. */
99102
ConsolePane<?> getConsolePane();
100103

101-
/** Gets the system clipboard associated with this UI. */
104+
/**
105+
* Gets the system clipboard associated with this UI, or null if not
106+
* applicable.
107+
*/
102108
SystemClipboard getSystemClipboard();
103109

104-
/** Creates a new display window housing the given display. */
110+
/**
111+
* Creates a new display window housing the given display, or null if not
112+
* applicable.
113+
*/
105114
DisplayWindow createDisplayWindow(Display<?> display);
106115

107116
/**
108117
* Creates a dialog prompter.
109-
*
118+
*
110119
* @param message The message in the dialog itself.
111120
* @param title The title of the dialog.
112121
* @param messageType The type of message. This typically is rendered as an
@@ -115,27 +124,29 @@ public interface UserInterface extends RichPlugin, Disposable {
115124
* as an exclamation point.
116125
* @param optionType The choices available when dismissing the dialog. These
117126
* choices are typically rendered as buttons for the user to click.
118-
* @return The newly created DialogPrompt object.
127+
* @return The newly created DialogPrompt object, or null if not applicable.
119128
*/
120129
DialogPrompt dialogPrompt(String message, String title,
121130
DialogPrompt.MessageType messageType, DialogPrompt.OptionType optionType);
122131

123132
/**
124133
* Prompts the user to choose a file.
125-
*
134+
*
126135
* @param file The initial value displayed in the file chooser prompt.
127136
* @param style The style of chooser to use:
128137
* <ul>
129138
* <li>{@link FileWidget#OPEN_STYLE}</li>
130139
* <li>{@link FileWidget#SAVE_STYLE}</li>
131140
* <li>{@link FileWidget#DIRECTORY_STYLE}</li>
132141
* </ul>
142+
* @return The {@link File} chosen by the user, or null if prompt is not
143+
* available
133144
*/
134145
File chooseFile(File file, String style);
135146

136147
/**
137148
* Prompts the user to choose a file.
138-
*
149+
*
139150
* @param title Title to use in the file chooser dialog.
140151
* @param file The initial value displayed in the file chooser prompt.
141152
* @param style The style of chooser to use:
@@ -144,6 +155,8 @@ DialogPrompt dialogPrompt(String message, String title,
144155
* <li>{@link FileWidget#SAVE_STYLE}</li>
145156
* <li>{@link FileWidget#DIRECTORY_STYLE}</li>
146157
* </ul>
158+
* @return The {@link File} chosen by the user, or null if prompt is not
159+
* available
147160
*/
148161
File chooseFile(String title, File file, String style);
149162

0 commit comments

Comments
 (0)