src/java.desktop/share/classes/java/awt/datatransfer/MimeType.java

Print this page




 216      * Retrieve the value associated with the given name, or null if there
 217      * is no current association.
 218      */
 219     public String getParameter(String name) {
 220         return parameters.get(name);
 221     }
 222 
 223     /**
 224      * Set the value to be associated with the given name, replacing
 225      * any previous association.
 226      *
 227      * @throw IllegalArgumentException if parameter or value is illegal
 228      */
 229     public void setParameter(String name, String value) {
 230         parameters.set(name, value);
 231     }
 232 
 233     /**
 234      * Remove any value associated with the given name.
 235      *
 236      * @throw IllegalArgumentExcpetion if parameter may not be deleted
 237      */
 238     public void removeParameter(String name) {
 239         parameters.remove(name);
 240     }
 241 
 242     /**
 243      * Return the String representation of this object.
 244      */
 245     public String toString() {
 246         return getBaseType() + parameters.toString();
 247     }
 248 
 249     /**
 250      * Return a String representation of this object
 251      * without the parameter list.
 252      */
 253     public String getBaseType() {
 254         return primaryType + "/" + subType;
 255     }
 256 




 216      * Retrieve the value associated with the given name, or null if there
 217      * is no current association.
 218      */
 219     public String getParameter(String name) {
 220         return parameters.get(name);
 221     }
 222 
 223     /**
 224      * Set the value to be associated with the given name, replacing
 225      * any previous association.
 226      *
 227      * @throw IllegalArgumentException if parameter or value is illegal
 228      */
 229     public void setParameter(String name, String value) {
 230         parameters.set(name, value);
 231     }
 232 
 233     /**
 234      * Remove any value associated with the given name.
 235      *
 236      * @throw IllegalArgumentException if parameter may not be deleted
 237      */
 238     public void removeParameter(String name) {
 239         parameters.remove(name);
 240     }
 241 
 242     /**
 243      * Return the String representation of this object.
 244      */
 245     public String toString() {
 246         return getBaseType() + parameters.toString();
 247     }
 248 
 249     /**
 250      * Return a String representation of this object
 251      * without the parameter list.
 252      */
 253     public String getBaseType() {
 254         return primaryType + "/" + subType;
 255     }
 256