Class HttpReplyHdr
- java.lang.Object
-
- org.apache.jmeter.protocol.http.proxy.HttpReplyHdr
-
public final class HttpReplyHdr extends Object
Utility class to generate HTTP responses of various types.- Version:
- $Revision: 1518164 $
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static StringformAccepted()Indicates the document was accepted.static StringformCreated()Indicates a new file was created.static StringformForbidden()Client if forbidden to get the request service.static StringformFound()Never seen this used.static StringformInternalError()The server had a problem and could not fulfill the request.static StringformMethod()The requested method is not implemented by the server.static StringformMoved()Indicates a requested URL has moved to a new address or name.static StringformNotAllowed()Indicates the client is not allowed to access the object.static StringformNotFound()The requested object was not found.static StringformNotImplemented()Server does not do the requested feature.static StringformNotImplemented(String reason)Server does not do the requested feature.static StringformNotModified()Indicates remote copy of the requested object is current.static StringformOk(String contentType, long contentLength)Forms a http ok reply headerstatic StringformOverloaded()Server is overloaded, client should try again latter.static StringformPartial()Indicates only a partial responce was sent.static StringformPaymentNeeded()Payment is required for service.static StringformServerNotFound()Indicates the client's proxies could not locate a server.static StringformTimeout()Indicates the request took to long.static StringformUnauthorized()Client not authorized for the request.
-
-
-
Method Detail
-
formOk
public static String formOk(String contentType, long contentLength)
Forms a http ok reply header- Parameters:
contentType- the mime-type of the contentcontentLength- the length of the content- Returns:
- a string with the header in it
-
formCreated
public static String formCreated()
Indicates a new file was created.- Returns:
- The header in a string;
-
formAccepted
public static String formAccepted()
Indicates the document was accepted.- Returns:
- The header in a string;
-
formPartial
public static String formPartial()
Indicates only a partial responce was sent.- Returns:
- The header in a string;
-
formMoved
public static String formMoved()
Indicates a requested URL has moved to a new address or name.- Returns:
- The header in a string;
-
formFound
public static String formFound()
Never seen this used.- Returns:
- The header in a string;
-
formMethod
public static String formMethod()
The requested method is not implemented by the server.- Returns:
- The header in a string;
-
formNotModified
public static String formNotModified()
Indicates remote copy of the requested object is current.- Returns:
- The header in a string;
-
formUnauthorized
public static String formUnauthorized()
Client not authorized for the request.- Returns:
- The header in a string;
-
formPaymentNeeded
public static String formPaymentNeeded()
Payment is required for service.- Returns:
- The header in a string;
-
formForbidden
public static String formForbidden()
Client if forbidden to get the request service.- Returns:
- The header in a string;
-
formNotFound
public static String formNotFound()
The requested object was not found.- Returns:
- The header in a string;
-
formInternalError
public static String formInternalError()
The server had a problem and could not fulfill the request.- Returns:
- The header in a string;
-
formNotImplemented
public static String formNotImplemented()
Server does not do the requested feature.- Returns:
- The header in a string;
-
formNotImplemented
public static String formNotImplemented(String reason)
Server does not do the requested feature.- Parameters:
reason- detailed information for causing the failure- Returns:
- The header in a string;
-
formOverloaded
public static String formOverloaded()
Server is overloaded, client should try again latter.- Returns:
- The header in a string;
-
formTimeout
public static String formTimeout()
Indicates the request took to long.- Returns:
- The header in a string;
-
formServerNotFound
public static String formServerNotFound()
Indicates the client's proxies could not locate a server.- Returns:
- The header in a string;
-
formNotAllowed
public static String formNotAllowed()
Indicates the client is not allowed to access the object.- Returns:
- The header in a string;
-
-