Class Error
- java.lang.Object
-
- com.microsoft.azure.cognitiveservices.knowledge.qnamaker.models.Error
-
- Direct Known Subclasses:
ErrorResponseError
public class Error extends Object
The error object. As per Microsoft One API guidelines - https://github.com/Microsoft/api-guidelines/blob/vNext/Guidelines.md#7102-error-condition-responses.
-
-
Constructor Summary
Constructors Constructor Description Error()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ErrorCodeType
code()
Get the code value.List<Error>
details()
Get the details value.InnerErrorModel
innerError()
Get the innerError value.String
message()
Get the message value.String
target()
Get the target value.Error
withCode(ErrorCodeType code)
Set the code value.Error
withDetails(List<Error> details)
Set the details value.Error
withInnerError(InnerErrorModel innerError)
Set the innerError value.Error
withMessage(String message)
Set the message value.Error
withTarget(String target)
Set the target value.
-
-
-
Method Detail
-
code
public ErrorCodeType code()
Get the code value.- Returns:
- the code value
-
withCode
public Error withCode(ErrorCodeType code)
Set the code value.- Parameters:
code
- the code value to set- Returns:
- the Error object itself.
-
message
public String message()
Get the message value.- Returns:
- the message value
-
withMessage
public Error withMessage(String message)
Set the message value.- Parameters:
message
- the message value to set- Returns:
- the Error object itself.
-
target
public String target()
Get the target value.- Returns:
- the target value
-
withTarget
public Error withTarget(String target)
Set the target value.- Parameters:
target
- the target value to set- Returns:
- the Error object itself.
-
withDetails
public Error withDetails(List<Error> details)
Set the details value.- Parameters:
details
- the details value to set- Returns:
- the Error object itself.
-
innerError
public InnerErrorModel innerError()
Get the innerError value.- Returns:
- the innerError value
-
withInnerError
public Error withInnerError(InnerErrorModel innerError)
Set the innerError value.- Parameters:
innerError
- the innerError value to set- Returns:
- the Error object itself.
-
-