Package de.xima.fc.mdl.fdv
Enum EResponseType
- java.lang.Object
-
- java.lang.Enum<EResponseType>
-
- de.xima.fc.mdl.fdv.EResponseType
-
- All Implemented Interfaces:
Serializable
,Comparable<EResponseType>
public enum EResponseType extends Enum<EResponseType>
An enumeration of possible HTTP response types.- Author:
- XIMA MEDIA GmbH
-
-
Enum Constant Summary
Enum Constants Enum Constant Description EMPTY
Only sends response headers with the HTTP response, but no body content.HTML
Sends an HTML document as the HTTP response.JSON
Sends a JSON string as the HTTP response.SHOW_FILE
Sends a binary file as the HTTP response.TEMPLATE
Sends a custom HTML template as the HTTP response.TEMPLATE_SYSTEM
Sends a system HTML template as the HTTP response.WEITERLEITUNG
Send a redirect (usually 303) as the HTTP response.XML
Sends an XMLstring as the HTTP response.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static EResponseType
valueOf(String name)
Returns the enum constant of this type with the specified name.static EResponseType[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
SHOW_FILE
public static final EResponseType SHOW_FILE
Sends a binary file as the HTTP response. You should also provide a content type. TheIServletResponse.getBinValue()
should contain the binary data of the file,IServletResponse.getValue()
should contain the file name.
-
TEMPLATE_SYSTEM
public static final EResponseType TEMPLATE_SYSTEM
Sends a system HTML template as the HTTP response. TheIServletResponse.getValue()
should be an HTML string. An HTML template is created by the system and this HTML string is placed inside the BODY.- See Also:
Textbaustein
-
WEITERLEITUNG
public static final EResponseType WEITERLEITUNG
Send a redirect (usually 303) as the HTTP response. TheIServletResponse.getValue()
should contain the target URL.
-
TEMPLATE
public static final EResponseType TEMPLATE
Sends a custom HTML template as the HTTP response. TheIServletResponse.getValue()
should be an HTML string. An HTML template is created by the system and this HTML string is placed inside the BODY.- See Also:
Textbaustein
-
HTML
public static final EResponseType HTML
Sends an HTML document as the HTTP response.
-
JSON
public static final EResponseType JSON
Sends a JSON string as the HTTP response. TheIServletResponse.getValue()
should contain the serialized JSON string.
-
XML
public static final EResponseType XML
Sends an XMLstring as the HTTP response. TheIServletResponse.getValue()
should contain the serialized XML string.
-
EMPTY
public static final EResponseType EMPTY
Only sends response headers with the HTTP response, but no body content.IServletResponse.getValue()
andIServletResponse.getBinValue()
will be ignored.
-
-
Method Detail
-
values
public static EResponseType[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (EResponseType c : EResponseType.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static EResponseType valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-
-