|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjavax.activation.CommandMap
javax.activation.MailcapCommandMap
public class MailcapCommandMap
Implementation of a command map using a mailcap file (RFC
1524). Mailcap files are searched for in the following places:
| Constructor Summary | |
|---|---|
MailcapCommandMap()
Default constructor. |
|
MailcapCommandMap(InputStream is)
Constructor specifying an input stream. |
|
MailcapCommandMap(String fileName)
Constructor specifying a filename. |
|
| Method Summary | |
|---|---|
void |
addMailcap(String mailcap)
Adds entries programmatically to the registry. |
DataContentHandler |
createDataContentHandler(String mimeType)
Returns the DCH for the specified MIME type. |
CommandInfo[] |
getAllCommands(String mimeType)
Returns all commands for the given MIME type. |
CommandInfo |
getCommand(String mimeType,
String cmdName)
Returns the command with the specified name for the given MIME type. |
String[] |
getNativeCommands(String mimeType)
Get the native commands for the given MIME type. |
CommandInfo[] |
getPreferredCommands(String mimeType)
Returns the list of preferred commands for a given MIME type. |
| Methods inherited from class javax.activation.CommandMap |
|---|
createDataContentHandler, getAllCommands, getCommand, getDefaultCommandMap, getMimeTypes, getPreferredCommands, setDefaultCommandMap |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public MailcapCommandMap()
public MailcapCommandMap(String fileName)
throws IOException
fileName - the name of the file to read mailcap entries from
IOExceptionpublic MailcapCommandMap(InputStream is)
is - the input stream to read mailcap entries from| Method Detail |
|---|
public CommandInfo[] getPreferredCommands(String mimeType)
getPreferredCommands in class CommandMapmimeType - the MIME typepublic CommandInfo[] getAllCommands(String mimeType)
getAllCommands in class CommandMapmimeType - the MIME type
public CommandInfo getCommand(String mimeType,
String cmdName)
getCommand in class CommandMapmimeType - the MIME typecmdName - the command verbpublic void addMailcap(String mailcap)
mailcap - a mailcap stringpublic DataContentHandler createDataContentHandler(String mimeType)
createDataContentHandler in class CommandMapmimeType - the MIME typepublic String[] getNativeCommands(String mimeType)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||