public class StandardErrorUnmarshaller extends AbstractErrorUnmarshaller<Node>
LegacyErrorUnmarshaller
exceptionClass
Constructor and Description |
---|
StandardErrorUnmarshaller()
Constructs a new unmarshaller that will unmarshall a standard AWS error
message as a generic AmazonServiceException object.
|
StandardErrorUnmarshaller(Class<? extends AmazonServiceException> exceptionClass)
Constructor allowing subclasses to specify a specific type of
AmazonServiceException to instantiating when populating the exception
object with data from the error message.
|
Modifier and Type | Method and Description |
---|---|
String |
getErrorPropertyPath(String property)
Returns the path to the specified property within an error response.
|
String |
parseErrorCode(Node in)
Returns the AWS error code for the specified error response.
|
String |
parseErrorCode(Node in,
XPath xpath) |
AmazonServiceException |
unmarshall(Node in) |
newException
public StandardErrorUnmarshaller()
public StandardErrorUnmarshaller(Class<? extends AmazonServiceException> exceptionClass)
exceptionClass
- The class of AmazonServiceException to create and populate
when unmarshalling the error message.public AmazonServiceException unmarshall(Node in) throws Exception
Exception
Unmarshaller.unmarshall(java.lang.Object)
public String parseErrorCode(Node in) throws Exception
in
- The DOM tree node containing the error response.Exception
- If any problems were encountered pulling out the AWS error
code.public String parseErrorCode(Node in, XPath xpath) throws Exception
Exception
Copyright © 2021. All rights reserved.