|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface TextEditorService
An interface to be implemented by all TextEditor systems
Method Summary | |
---|---|
void |
addMimeType(String mimeType,
Icon icon)
Associates a given icon with a mime-type. |
List |
editors()
Get a list of all active editors. |
TextEditor |
getCurrentEditor()
Get the "current" text editor. |
Icon |
getIconForMimeType(String mimeType)
Retrieve the icon for a mime-type |
void |
show(File f,
String mimeType)
Show a file in an editor window |
void |
show(Reader reader,
String mimeType,
String title)
Show text read from a Reader in an editor |
void |
show(String text,
String mimeType,
String title)
Show the given text in a new editor window |
void |
show(URL url,
String mimeType)
Show a file from an URL in an editor window |
Method Detail |
---|
void show(String text, String mimeType, String title)
text
- The text to displaymimeType
- The mime-type to be associated with the editortitle
- The title for the editorvoid show(File f, String mimeType) throws IOException
f
- The file to showmimeType
- The mime-type for the file
IOException
- If there is a problem reading the file.void show(URL url, String mimeType) throws IOException
url
- The URL of the filemimeType
- The mime-type for the file
IOException
- If there is a problem reading the file.void show(Reader reader, String mimeType, String title) throws IOException
reader
- The reader to read from.mimeType
- The mime-type to associate with the read texttitle
- The title for the editor window
IOException
- If there is a problem reading from the Reader.void addMimeType(String mimeType, Icon icon)
mimeType
- The mime-typeicon
- The associated iconIcon getIconForMimeType(String mimeType)
mimeType
- The mime-type to search for
null
if none exists.TextEditor getCurrentEditor()
null
if none is selectedList editors()
TextEditor
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |