java.awt.datatransfer
Class SystemFlavorMap
java.lang.Object
|
+--java.awt.datatransfer.SystemFlavorMap
All Implemented Interfaces:
FlavorMap, FlavorTable
This class maps between native platform type names and DataFlavors.
XXX - The current implementation does no mapping at all.
Since:Author:- Mark Wielaard (mark@klomp.org)
decodeDataFlavor
public static DataFlavor decodeDataFlavor(java.lang.String name)
Returns the data flavor given the native type name
or null when no such data flavor exists.
Parameters:
decodeJavaMIMEType
public static String decodeJavaMIMEType(java.lang.String name)
Returns the java mime type for the given the native type name.
Parameters:
encodeDataFlavor
public static String encodeDataFlavor(java.awt.datatransfer.DataFlavor df)
Returns the native type name for the given data flavor.
Parameters:
encodeJavaMIMEType
public static String encodeJavaMIMEType(java.lang.String mime)
Returns the native type name for the given java mime type.
Parameters:
getDefaultFlavorMap
public static FlavorMap getDefaultFlavorMap()
Returns the default (instance) (System)FlavorMap.
getFlavorsForNative
public List getFlavorsForNative(java.lang.String nat)
Parameters:
getFlavorsForNatives
public Map getFlavorsForNatives(java.lang.String[] natives)
Maps the specified native type names to DataFlavor
's.
The returned Map
has keys that are strings and values
that are DataFlavor
's. The returned map may be
modified. This can be useful for implementing nested mappings.
Parameters:
Returns:
- A
Map
of data flavors to native type names.
getNativesForFlavor
public List getNativesForFlavor(java.awt.datatransfer.DataFlavor flav)
Parameters:
getNativesForFlavors
public Map getNativesForFlavors(java.awt.datatransfer.DataFlavor[] flavors)
Maps the specified DataFlavor
objects to the native
data type name. The returned Map
has keys that are
the data flavors and values that are strings. The returned map
may be modified. This can be useful for implementing nested mappings.
Parameters:
Returns:
- A
Map
of native data types to data flavors.
isJavaMIMEType
public static boolean isJavaMIMEType(java.lang.String name)
Returns true if the native type name can be represented as
a java mime type.
Parameters: