public static class AddOrUpdateResourceHelper.ResourceOperationResult extends Object
Modifier and Type | Field and Description |
---|---|
private String |
_errorMessage
Type of error in case of unsuccessful operation
|
private List<Resource> |
_resources
The created or updated resource(s)
|
private boolean |
_success
Indicates if the operation was successful
|
private boolean |
_unzip
Indicates if an unzip operation was executed
|
Modifier | Constructor and Description |
---|---|
protected |
ResourceOperationResult(List<Resource> resources)
constructor in case of a successful unzip operation
|
protected |
ResourceOperationResult(Resource resource)
constructor in case of a successful operation
|
protected |
ResourceOperationResult(String errorMessage)
constructor in case of an error
|
Modifier and Type | Method and Description |
---|---|
String |
getErrorMessage()
Retrieves the errorMessage
|
Resource |
getResource()
Retrieves the resource
Note that
getResources() should be used in case of an unzip. |
List<Resource> |
getResources()
Retrieves the list of resources, in case of an unzip.
|
boolean |
isSuccess()
Retrieves the success
|
boolean |
isUnzip()
Retrieves the unzip
|
private final List<Resource> _resources
private final boolean _unzip
private final boolean _success
private final String _errorMessage
protected ResourceOperationResult(Resource resource)
resource
- The resource of this operationprotected ResourceOperationResult(List<Resource> resources)
resources
- The list of resource for this operationprotected ResourceOperationResult(String errorMessage)
errorMessage
- The error message.public Resource getResource()
getResources()
should be used in case of an unzip.public List<Resource> getResources()
public boolean isUnzip()
public boolean isSuccess()
public String getErrorMessage()