Class ErrorInfo
java.lang.Object
org.apache.pekko.http.scaladsl.model.ErrorInfo
- All Implemented Interfaces:
Serializable,scala.Equals,scala.Product
Two-level model of error information.
The summary should explain what is wrong with the request or response *without* directly
repeating anything present in the message itself (in order to not open holes for XSS attacks),
while the detail can contain additional information from any source (even the request itself).
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic ErrorInfoINTERNAL APIbooleanINTERNAL APIdetail()booleanformat(boolean withDetail) static ErrorInfofromCompoundString(String message) Allows constructing anErrorInfofrom a single string.intproductElement(int n) summary()toString()withErrorHeaderName(String headerName) withFallbackSummary(String fallbackSummary) withSummary(String newSummary) withSummaryPrepended(String prefix) Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface scala.Product
productElementName, productElementNames, productIterator, productPrefix
-
Constructor Details
-
ErrorInfo
-
ErrorInfo
INTERNAL API
-
-
Method Details
-
apply
INTERNAL API -
unapply
-
fromCompoundString
Allows constructing anErrorInfofrom a single string. Used for example when catching exceptions generated by the header value parser, which doesn't provide summary/details information but structures its exception messages accordingly.- Parameters:
message- (undocumented)- Returns:
- (undocumented)
-
summary
-
detail
-
errorHeaderName
-
withSummary
-
withSummaryPrepended
-
withErrorHeaderName
-
withFallbackSummary
-
formatPretty
-
format
-
copy
INTERNAL API -
canEqual
- Specified by:
canEqualin interfacescala.Equals
-
equals
-
productElement
- Specified by:
productElementin interfacescala.Product
-
productArity
public int productArity()- Specified by:
productArityin interfacescala.Product
-
toString
-