package jenkins.plugins.http_request;

import hudson.util.ListBoxModel;

/**
 * @author James Chapman
 */
public enum MimeType {

    NOT_SET(""),
    TEXT_HTML("text/html"),
    TEXT_PLAIN("text/plain"),
    APPLICATION_JSON("application/json"),
    APPLICATION_TAR("application/x-tar"),
    APPLICATION_ZIP("application/zip"),
    APPLICATION_OCTETSTREAM("application/octet-stream");

    private final String value;

    MimeType(String value) {
        this.value = value;
    }

    public String getValue() {
        return value;
    }

    public static ListBoxModel getContentTypeFillItems() {
        ListBoxModel items = new ListBoxModel();
        for (MimeType mimeType : values()) {
            items.add(mimeType.name());
        }
        return items;
    }

}

@@ -123,20 +123,17 @@
 Type %7B%0A%0A
-    
+%09
 NOT_SET(
@@ -136,20 +136,16 @@
 SET(%22%22),
-%0A   
  TEXT_HT
@@ -160,20 +160,16 @@
 /html%22),
-%0A   
  TEXT_PL
@@ -182,28 +182,79 @@
 ext/plain%22),
-%0A   
+ APPLICATION_FORM(%22application/x-www-form-urlencoded%22),
  APPLICATION
@@ -279,20 +279,16 @@
 /json%22),
-%0A   
  APPLICA
@@ -317,20 +317,16 @@
 x-tar%22),
-%0A   
  APPLICA
@@ -334,16 +334,20 @@
 ION_ZIP(
+%0A%09%09%09
 %22applica
@@ -357,20 +357,16 @@
 n/zip%22),
-%0A   
  APPLICA
@@ -412,20 +412,17 @@
 eam%22);%0A%0A
-    
+%09
 private 
@@ -442,20 +442,17 @@
 value;%0A%0A
-    
+%09
 MimeType
@@ -468,24 +468,18 @@
 alue) %7B%0A
-        
+%09%09
 this.val
@@ -486,35 +486,29 @@
 ue = value;%0A
-    %7D%0A%0A    
+%09%7D%0A%0A%09
 public Strin
@@ -526,41 +526,34 @@
 ) %7B%0A
-        
+%09%09
 return 
+this.
 value;%0A
-    %7D%0A%0A    
+%09%7D%0A%0A%09
 publ
@@ -603,24 +603,18 @@
 ems() %7B%0A
-        
+%09%09
 ListBoxM
@@ -646,24 +646,18 @@
 odel();%0A
-        
+%09%09
 for (Mim
@@ -689,20 +689,11 @@
 ) %7B%0A
-            
+%09%09%09
 item
@@ -720,26 +720,14 @@
 ));%0A
-        %7D%0A        
+%09%09%7D%0A%09%09
 retu
@@ -740,12 +740,9 @@
 ms;%0A
-    
+%09
 %7D%0A%0A%7D

Add supports for HTML FORM MimeType